docs/src/edit.md

Sun, 17 Dec 2023 15:33:50 +0100

author
Mike Becker <universe@uap-core.de>
date
Sun, 17 Dec 2023 15:33:50 +0100
changeset 800
30d484806c2b
parent 720
2b8a65ed6f4c
permissions
-rw-r--r--

fix faulty string to int conversion utilities

Probably it was expected that errno is set to EINVAL when illegal characters are encountered. But this is not standard and does not happen on every system, allowing illegal strings to be parsed as valid integers.

714
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
1 ---
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
2 title: 'dav edit'
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
3 ---
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
4
720
2b8a65ed6f4c adds support for -L option in dav edit
Mike Becker <universe@uap-core.de>
parents: 714
diff changeset
5 **`dav edit [-pc] [-k <key>] [-V <version>] [-L <lock>] <url>`**
714
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
6
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
7 Downloads a resources and opens an editor. If there is no resource at the
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
8 specified location, it is attempted to create a fresh resource.
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
9 The resource is downloaded to a temporary file and re-uploaded only if you save
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
10 any changes to that file.
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
11
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
12 The default editor `vi` can be changed with the `EDITOR` environment variable.
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
13
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
14 This command transparently handles decryption and encryption. If you download
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
15 and open a plain text file and request content encryption (either by config or
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
16 by command line option) the file will be re-uploaded with content encryption.
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
17 However, a present file will keep its (plain text) file name in any case.
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
18
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
19 **`-p`** disable file name encryption and decryption
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
20
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
21 **`-c`** enable file name and content encryption
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
22
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
23 **`-k <key>`** use the specified key for encryption. The key must be configured in
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
24 the config.xml file
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
25
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
26 **`-V <version>`** downloads a specific version of the resource. Available versions can be listed with the *list-versions* command
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
27
720
2b8a65ed6f4c adds support for -L option in dav edit
Mike Becker <universe@uap-core.de>
parents: 714
diff changeset
28 **`-L <lock>`** use a lock token. See [dav lock][1]
714
10a5d6ce0906 adds documentation for the edit command
Mike Becker <universe@uap-core.de>
parents:
diff changeset
29
720
2b8a65ed6f4c adds support for -L option in dav edit
Mike Becker <universe@uap-core.de>
parents: 714
diff changeset
30 [1]: ./lock.html
2b8a65ed6f4c adds support for -L option in dav edit
Mike Becker <universe@uap-core.de>
parents: 714
diff changeset
31

mercurial