cmd: add shell completion and man pages generators

This commit is contained in:
Nicola Murino
2020-07-08 23:21:33 +02:00
parent 0ea2ca3141
commit 96cbce52f9
6 changed files with 138 additions and 1 deletions

View File

@@ -9,6 +9,7 @@ Usage:
sftpgo [command]
Available Commands:
gen A collection of useful generators
help Help about any command
initprovider Initializes the configured data provider
portable Serve a single directory
@@ -36,6 +37,8 @@ Log file can be rotated on demand sending a `SIGUSR1` signal on Unix based syste
If you don't configure any private host key, the daemon will use `id_rsa` and `id_ecdsa` in the configuration directory. If these files don't exist, the daemon will attempt to autogenerate them (if the user that executes SFTPGo has write access to the `config-dir`). The server supports any private key format supported by [`crypto/ssh`](https://github.com/golang/crypto/blob/master/ssh/keys.go#L33).
The `gen` command allows to generate completion scripts for your shell and man pages. Currently the man pages visual representation is wrong, take a look at this upstream [bug](https://github.com/spf13/cobra/issues/1049) for more details.
## Configuration file
The configuration file contains the following sections: