annotate cmd/sievemgr/doc.go @ 22:fc5e6970a0d5 default tip

Add support for specifying an authorization identity on the command line
author Guido Berhoerster <guido+sievemgr@berhoerster.name>
date Wed, 17 Feb 2021 07:50:55 +0100
parents 2b799ca75d96
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
1 /*
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
2 The sievemgr command is a ManageSieve client.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
3
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
4 Usage:
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
5
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
6 sievemgr [-f config] info [-A authzid] [-a account]
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
7 sievemgr [-f config] list [-A authzid] [-a account]
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
8 sievemgr [-f config] get [-A authzid] [-a account] script
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
9 sievemgr [-f config] put [-A authzid] [-a account] script [file]
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
10 sievemgr [-f config] activate [-A authzid] [-a account] script
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
11 sievemgr [-f config] deactivate [-A authzid] [-a account]
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
12 sievemgr [-f config] delete [-A authzid] [-a account] script
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
13 sievemgr [-f config] check [-A authzid] [-a account] [file]
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
14 sievemgr [-f config] checkspace [-A authzid] [-a account] script [file]
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
15 sievemgr [-f config] rename [-A authzid] [-a account] old new
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
16 sievemgr [-f config] edit [-A authzid] [-a account] script
10
44c07eb8ef08 Add man subcommand to display the user manual
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 9
diff changeset
17 sievemgr [-f config] man
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
18
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
19 Description:
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
20
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
21 sievemgr is a client for managing Sieve scripts on remote servers via the
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
22 ManageSieve Protocol (RFC 5804). Given valid credentials, sievemgr can be
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
23 invoked non-interactively in order to retrieve a list of all script scripts,
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
24 retrieve the scripts themselves, publish scripts on a server, or delete them.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
25 Furthermore, it can be used to change the active script and to display
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
26 information about the server.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
27
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
28 The ManageSieve server may either be referred to by a domain name or by its IP
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
29 address or hostname and optionally the port. If only a domain name was
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
30 specified a DNS service lookup is performed in order to determine the hostname
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
31 and port of the ManageSieve server. In case no service record exists or no
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
32 port was specified sievemgr will fall back to port 4190.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
33
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
34 sievemgr only supports authentication using the SASL PLAIN mechanism and
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
35 requires support for TLS-encrypted connections via the STARTTLS command when
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
36 connecting to a server other than localhost.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
37
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
38 Configuration File:
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
39
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
40 If a configuration file is not explicitly specified using the -f option
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
41 sievemgr will open the default configuration file in a platform-dependent
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
42 location:
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
43
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
44 * on Unix either $XDG_CONFIG_HOME/sievemegr/sievemgr.conf if
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
45 XDG_CONFIG_HOME is set or $HOME/.config/sievemegr/sievemgr.conf
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
46 * on Darwin $HOME/Library/Application Support/sievemegr/sievemgr.conf
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
47 * on Windows %APPDATA%\sievemgr\sievemgr.conf
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
48
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
49 The owner of the file must match the effective user and the permissions of the
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
50 file must be set to disallow access by group or others.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
51
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
52 Tokens in the configuration file are seperated by spaces, tabs, and newlines
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
53 and there are three types of tokens: identifiers, strings, and numbers.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
54 Identifiers consist of the letters a-z and A-Z, numbers of 0-9. Strings are
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
55 enclosed in double quotes, literal double quotes can be escaped with a
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
56 backslash and a literal backslash is escaped with another backslash.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
57
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
58 The following tokens are recognized:
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
59
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
60 account "name"
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
61 Define an account which is referred to by name. The account
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
62 definition ends when another account token is encountered or at
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
63 the end of the file.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
64
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
65 default
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
66 Set this as the default account.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
67
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
68 host "name"
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
69 Specify the host- or domainname of the ManageSieve server.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
70
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
71 port number
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
72 Specifiy the port number of the ManageSieve server. If left
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
73 out and the host token refers to a domainname, sievmgr will
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
74 query DNS for a SRV record for a ManageSieve service associated
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
75 with the domain and fall back to port 4190.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
76
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
77 user "name"
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
78 Set the username of the account.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
79
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
80 pass "password"
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
81 Set the password of the account.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
82
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
83 insecure
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
84 Optionally specify that verification of the certificate
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
85 presented by the server when making a TLS connection should be
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
86 skipped. This renders the connection insecure and should only
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
87 be used for testing purposes.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
88
17
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
89 An example configuration with two accounts is provided below:
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
90
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
91 account "work" host "mail.example.com" port 2000 user "foo"
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
92 account "private" default host "example.net" user "baz" pass "qux"
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
93
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
94 The first account must be explicitly referred to by its name "work". sievemgr
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
95 will directly connect to the host "mail.example.com" using the non-standard
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
96 port 2000 since both host and port are given. The user will be prompted for
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
97 the account password before authentication is performed with the username
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
98 "foo".
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
99
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
100 The second account is the default account, host and port name of the server
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
101 will be determined by looking up the corresponding SRV record associated with
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
102 the domain "example.net". Authentication will be performed non-interactively
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
103 with the username "baz" and password "qux".
2b799ca75d96 Add configuration example to the documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 10
diff changeset
104
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
105 Global Options:
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
106
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
107 -f config
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
108 Set the name of the configuration file to config.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
109
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
110 Common Options:
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
111
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
112 -A authzid
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
113 Specify the authorization identity to assume if permitted by
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
114 the given account credentials.
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
115
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
116 -a account
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
117 Select account from the configuration file.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
118
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
119 Subcommands:
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
120
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
121 sievemgr [-f config] info [-A authzid] [-a account]
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
122
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
123 Displays information about the ManageSieve server. This includes conformance to
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
124 RFC 5804, support for TLS connections, supported extensions, available SASL
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
125 authentication mechanisms, and supported notification methods.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
126
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
127 sievemgr [-f config] list [-A authzid] [-a account]
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
128
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
129 Lists all scripts on the server and indicate which of the is the currently
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
130 active script.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
131
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
132 sievemgr [-f config] get [-A authzid] [-a account] script
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
133
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
134 Fetch the contents of script from the server.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
135
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
136 sievemgr [-f config] put [-A authzid] [-a account] script [file]
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
137
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
138 Submit file under the name script to the server. If file is not specified,
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
139 read the script from standard input. The server will reject a script if it is
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
140 invalid or a storage quota is exceeded.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
141
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
142 sievemgr [-f config] activate [-A authzid] [-a account] script
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
143
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
144 Set script as the active script on the server.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
145
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
146 sievemgr [-f config] deactivate [-A authzid] [-a account]
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
147
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
148 Deactivate the currently active script on the server.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
149
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
150 sievemgr [-f config] delete [-A authzid] [-a account] script
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
151
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
152 Delete script from the server.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
153
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
154 sievemgr [-f config] check [-A authzid] [-a account] [file]
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
155
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
156 Check if file is a valid sieve script. If file is not specified, read the
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
157 script from standard input.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
158
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
159 sievemgr [-f config] checkspace [-A authzid] [-a account] script [file]
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
160
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
161 Check if the script in file can be stored on the server without exceeding the
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
162 storage quota. If script already exists the server will take overwriting it
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
163 into account. If file is not specified, read the script from standard input.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
164
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
165 sievemgr [-f config] rename [-A authzid] [-a account] old new
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
166
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
167 Rename the script old to new.
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
168
22
fc5e6970a0d5 Add support for specifying an authorization identity on the command line
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 17
diff changeset
169 sievemgr [-f config] edit [-A authzid] [-a account] script
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
170
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
171 Retrieve a copy of script and start the editor referred to in the $EDITOR
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
172 environment variable. If the local copy has not been modified or the editor
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
173 exits with a non-zero exit status the local copy of script will not be
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
174 submitted to the server. In case of errors the local copy of the script will
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
175 be preserved.
10
44c07eb8ef08 Add man subcommand to display the user manual
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 9
diff changeset
176
44c07eb8ef08 Add man subcommand to display the user manual
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 9
diff changeset
177 sievemgr [-f config] man
44c07eb8ef08 Add man subcommand to display the user manual
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 9
diff changeset
178
44c07eb8ef08 Add man subcommand to display the user manual
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents: 9
diff changeset
179 Display the user manual.
9
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
180 */
7ce77ceeaccc Add documentation
Guido Berhoerster <guido+sievemgr@berhoerster.name>
parents:
diff changeset
181 package main