[CRIU] [PATCH 12/15] criu --help: rectify --join-ns

Kir Kolyshkin kir at openvz.org
Tue Aug 30 16:58:15 PDT 2016


* Fix English and rephrase
* Mark with curly braces that PID and NS_FILE are exclusive options
* Fix 80 columns violations
* Remove usage examples
* Remove the "experimental feature" warning
* Add an empty line before "Check options" header

As for removals, I believe --help output is not the proper place for
examples or notices.

Was:
  -J|--join-ns NS:PID|NS_FILE[,EXTRA_OPTS]
                        Join exist namespace and restore process in it.
                        Namespace can be specified in pid or file path format.
                            --join-ns net:12345 or --join-ns net:/foo/bar.
                        Extra_opts is optional, for now only user namespace support:
                            --join-ns user:PID,UID,GID to specify uid and gid.
                        Please NOTE: join-ns with user-namespace is not fully tested.
                        It may be dangerous to use this feature
Check options:

Now:
  -J|--join-ns NS:{PID|NS_FILE}[,OPTIONS]
                        Join existing namespace and restore process in it.
                        Namespace can be specified as either pid or file path.
                        OPTIONS can be used to specify parameters for userns:
                            user:PID,UID,GID

Signed-off-by: Kir Kolyshkin <kir at openvz.org>
---
 criu/crtools.c | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/criu/crtools.c b/criu/crtools.c
index bd41129..fa1e387 100644
--- a/criu/crtools.c
+++ b/criu/crtools.c
@@ -904,14 +904,12 @@ usage:
 "                            file[mnt_id:inode]\n"
 "  --empty-ns net        Create a namespace, but don't restore its properies\n"
 "                        (assuming it will be restored by action scripts)\n"
-"  -J|--join-ns NS:PID|NS_FILE[,EXTRA_OPTS]\n"
-"			Join exist namespace and restore process in it.\n"
-"			Namespace can be specified in pid or file path format.\n"
-"			    --join-ns net:12345 or --join-ns net:/foo/bar.\n"
-"			Extra_opts is optional, for now only user namespace support:\n"
-"			    --join-ns user:PID,UID,GID to specify uid and gid.\n"
-"			Please NOTE: join-ns with user-namespace is not fully tested.\n"
-"			It may be dangerous to use this feature\n"
+"  -J|--join-ns NS:{PID|NS_FILE}[,OPTIONS]\n"
+"			Join existing namespace and restore process in it.\n"
+"			Namespace can be specified as either pid or file path.\n"
+"			OPTIONS can be used to specify parameters for userns:\n"
+"			    user:PID,UID,GID\n"
+"\n"
 "Check options:\n"
 "  without any arguments, \"criu check\" checks availability of absolutely required\n"
 "  kernel features; if any of these features is missing dump and restore will fail\n"
-- 
2.7.4



More information about the CRIU mailing list