diff --git a/LICENSE b/LICENSE index e4d88d2..37d6c19 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2022, Michael Santos +Copyright (c) 2022-2023, Michael Santos Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above diff --git a/lib/stdio.ex b/lib/stdio.ex index 78b03d1..557d1f3 100644 --- a/lib/stdio.ex +++ b/lib/stdio.ex @@ -45,8 +45,8 @@ defmodule Stdio do ## Overview `Stdio` manages system processes. The process standard output (`stdout`) - and standard error (`stderr`) are represented as `Stream`'s of - `t:stdio/0` tuples. `pipe!/4` reads standard input (`stdin`) from a + and standard error (`stderr`) are represented as `Stream`s of + `t:stdio/0` tuples. `pipe!/4` reads standard input (`stdin`) from a binary stream. * system processes run as [foreground @@ -73,7 +73,7 @@ defmodule Stdio do iex> ["hello\n"] |> Stdio.pipe!("sed -u 's/hello/bye/'") |> Enum.to_list() [stdout: "bye\n", exit_status: 0] - > #### Unbuffer Output {: .info} + > #### Note {: .info} > Process output may be buffered. The pipe example > unbuffers the output by using the `-u` option of > [sed(1)](https://man7.org/linux/man-pages/man1/sed.1.html). @@ -83,7 +83,7 @@ defmodule Stdio do > #### Warning {: .warning} > Some behaviours, notably `Stdio.Container` and `Stdio.Jail`, > require the system supervisor (not the beam process!) to be running as - > the `root` user. See `setuid/0` for instructions on how to set it up. + > the `root` user. See `setuid/0` for instructions for set up. Behaviours may change the root filesystem for the process. The default `chroot(2)` directory hierarchy can be created by running: @@ -212,7 +212,7 @@ defmodule Stdio do Function run during stream termination. `c:onexit/1` runs when the stream is closed. The function can perform - clean up and signal any lingering processses. Returns `true` if + clean up and signal any lingering processes. Returns `true` if subprocesses were found to be running during cleanup. """ @callback onexit(Keyword.t()) :: (Stdio.ProcessTree.t() -> boolean()) @@ -268,7 +268,7 @@ defmodule Stdio do ## ops - Provides a sequence of system calls to perform on the subprocess + Provides a sequence of system calls to run on the subprocess. ## onerror diff --git a/lib/stdio/container.ex b/lib/stdio/container.ex index 0daf533..92c35b0 100644 --- a/lib/stdio/container.ex +++ b/lib/stdio/container.ex @@ -17,9 +17,9 @@ defmodule Stdio.Container do ## Operations - > #### Mount Namespace Root (chroot) Directory {: .info} - > The chroot directory structure must be created before using this - > behaviour. + > #### Note {: .info} + > To mount a namespaced root (chroot) directory, the chroot directory + > structure must be created before using this behaviour. > > See `make_chroot_tree!/0` and `make_chroot_tree!/1`. diff --git a/lib/stdio/rootless.ex b/lib/stdio/rootless.ex index 4ece041..e3327a1 100644 --- a/lib/stdio/rootless.ex +++ b/lib/stdio/rootless.ex @@ -21,9 +21,9 @@ defmodule Stdio.Rootless do ## Operations - > #### Mount Namespace Root (chroot) Directory {: .info} - > The chroot directory structure must be created before using this - > behaviour. + > #### Note {: .info} + > To mount a namespaced root (chroot) directory, the chroot directory + > structure must be created before using this behaviour. > > See `Stdio.Container.make_chroot_tree!/0` and > `Stdio.Container.make_chroot_tree!/1`. diff --git a/test/stdio_test.exs b/test/stdio_test.exs index c86a7d4..987fa4f 100644 --- a/test/stdio_test.exs +++ b/test/stdio_test.exs @@ -448,7 +448,7 @@ defmodule StdioDocTest do use ExUnit.Case # The Stdio doctests contain some Linux specific tests. As a workaround, - # seperate the doctests so they can be skipped on other platforms. + # separate the doctests so they can be skipped on other platforms. @moduletag :linux doctest Stdio