The following pull request was submitted through Github.
It can be accessed and reviewed at: https://github.com/lxc/lxd/pull/3216

This e-mail was sent by the LXC bot, direct replies will not reach the author
unless they happen to be subscribed to this list.

=== Description (from pull-request) ===
Closes #3214

Signed-off-by: Stéphane Graber <[email protected]>
From 86e2f096fec0a06caf83c56c5c2820aa27ba99fd Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?St=C3=A9phane=20Graber?= <[email protected]>
Date: Mon, 24 Apr 2017 12:15:36 -0400
Subject: [PATCH] lxc: Show all commands in "man lxc"
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Closes #3214

Signed-off-by: Stéphane Graber <[email protected]>
---
 lxc/main.go    | 3 +--
 lxc/manpage.go | 2 +-
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/lxc/main.go b/lxc/main.go
index 1287d14..a8af4be 100644
--- a/lxc/main.go
+++ b/lxc/main.go
@@ -62,8 +62,7 @@ func run() error {
        }
 
        if len(os.Args) >= 2 && (os.Args[1] == "--all") {
-               os.Args[1] = "help"
-               os.Args = append(os.Args, "--all")
+               os.Args = []string{os.Args[0], "help", "--all"}
        }
 
        if shared.StringInSlice("--version", os.Args) {
diff --git a/lxc/manpage.go b/lxc/manpage.go
index 5dc07c1..697f015 100644
--- a/lxc/manpage.go
+++ b/lxc/manpage.go
@@ -50,7 +50,7 @@ func (c *manpageCmd) run(_ *lxd.Config, args []string) error {
        }
 
        // Generate the main manpage
-       err = help2man(execName, "LXD - client", filepath.Join(args[0], 
fmt.Sprintf("lxc.1")))
+       err = help2man(fmt.Sprintf("%s --all", execName), "LXD - client", 
filepath.Join(args[0], fmt.Sprintf("lxc.1")))
        if err != nil {
                return fmt.Errorf(i18n.G("Failed to generate 'lxc.1': %v"), err)
        }
_______________________________________________
lxc-devel mailing list
[email protected]
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to