# HG changeset patch # User Mike Becker # Date 1501932927 -7200 # Node ID 3070d72f54af410da6fbe42c546f4ce16308339f # Parent ddb5e8f2a43dcf0319a9e6a5176dd7385f3c0823 more minor improvements to the documentation diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/copy.html --- a/docs/html/copy.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/copy.html Sat Aug 05 13:35:27 2017 +0200 @@ -72,7 +72,7 @@

The command uses a single WebDAV COPY request to duplicate the resources. You may use file name and path decryption to copy and encrypted resource. Please note that the copy will always be located at url2, so the top most collection name will not be disguised. See encryption for more details on how encryption works.

-p disable file name and path decryption for url1

-c enable file name and path decryption for url1

-

-O override the destination resource

+

-O overwrite the destination resource

-L <lock> use a lock token. See dav lock

Command alias: cp

diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/date.html --- a/docs/html/date.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/date.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,7 +66,7 @@

dav date

date [url]

-

The purpose of this command is to get the current date from a server and print it to stdout (HTTP date format). This in useful in combination with the -U option for the list and get command.

+

The purpose of this command is to get the current date from a server and print it to stdout (HTTP date format). This in useful in combination with the -u option for the list and get command.

The url can be any http url. If no url is specified, the local time is used.

Example: incremental dav get

It is possible to download only resources, which are modified since a specified date. The date command allows you to easily store the date of the last get.

@@ -74,7 +74,7 @@ ... $ dav date myserv > last_get

After some resources are changed on the server, you can download only the modified files.

-
$ dav get -R -U `cat last_get` myserv/col/
+
$ dav get -R -u `cat last_get` myserv/col/
diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/get-property.html --- a/docs/html/get-property.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/get-property.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,15 +66,15 @@

dav get-property

get-property [-pc] [-n <uri>] <url> <property>

-

Gets a specified resource property. Every WebDAV property has a name and an XMl namespace. A namespace can be specified with the -n option or with a prefixed name. A prefix and property name are separated by an :

+

Gets a specific resource property. Every WebDAV property has a name and an XML namespace. A namespace can be specified with the -n option or with a prefixed name. The prefix and property name are separated by a : as usual.

Example: D:creationdate

D is the prefix, creationdate is the name.

-

There are only two available prefixes:

+

There are only two available prefixes by default:

  1. D for the DAV: namespace
  2. idav for http://davutils.org/
-

To use an other namespace, use the -n option.

+

To use another namespace, use the -n option.

If the property name has no prefix, and no namespace is specified, the default namespace DAV: is used.

-p disable file name and path decryption if enabled

-c enable file name and path decryption

diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/get.html --- a/docs/html/get.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/get.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,12 +66,12 @@

dav get

get [-pcR] [-o <file>] [-u <date>] <url>

-

Downloads a resource. It can also download collections and its child resources. When downloading a single resource, the default local file name is the resource name. When downloading collections, it does NOT create a local directory with the collection's name and places it children in there, but it downloads the children directly to the current working directory.

+

Downloads a resource. This command also downloads collections and its child resources when the -R option is used. When downloading a single resource, the default local file name is the resource name. When downloading collections, it does not create a local directory with the collection's name and places its children in there, but it downloads the children directly to the current working directory.

-p disable file name and content decryption. You get exactly what is stored on the server.

-c enable file name and content decryption

-R download a collection

-o <file> specify the local output file. A - indicates stdout

-

-u <date> download only files which are modified since the specified date. Uses the http date format

+

-u <date> download only files which are modified since the specified date. Uses the HTTP date format

diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/getting-started.html --- a/docs/html/getting-started.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/getting-started.html Sat Aug 05 13:35:27 2017 +0200 @@ -68,9 +68,9 @@

Test

After successful installation you can test dav with your WebDAV server.

dav list http://example.com/webdav/
-

This lists all child resources of the specified collection. If you are unfamiliar to WebDAV terminology this means basically listing all files in a directory, similar to the ls unix tool. Infact you can also write dav ls instead of dav list and there is also a -l option like ls has one.

+

This lists all child resources of the specified collection. If you are unfamiliar to WebDAV terminology this means basically listing all files in a directory, similar to the ls unix tool. Actually you can also write dav ls instead of dav list and there is also an -l option similarly to the unix tool ls.

Create a repository

-

All dav commands are expecting a url argument, but it may be a bit cumbersome to type a full url every time. But you can configure a repository in the dav configuration file ($HOME/.dav/config.xml) with the servers url, optional authentication information and other options. After that you can access a webdav server just with the repository name and an optional path.

+

All dav commands are expecting an url argument, but it may be a bit cumbersome to type a full url every time. But you can configure a repository in the dav configuration file ($HOME/.dav/config.xml) with the servers url, optional authentication information and other options. Afterwards you can access a webdav server just with the repository name and an optional path.

So when you have created a repository with the name myserv and the url http://example.com/webdav/, you can just type

dav list myserv

You can add a path to the repository name to access an other url

diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/info.html --- a/docs/html/info.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/info.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,9 +66,9 @@

dav info

info [-pc] <url>

-

Prints some information and lists all properties for the resource specified by url.

+

Prints some information and lists all properties for the resource specified by url.

Example 1: info of a collection

-

In this example myserv is a configured repository with the base url https://example.com/webdav/. Because col is not encrypted, the url is just the path appended to base url.

+

In this example myserv is a configured repository with the base url https://example.com/webdav/. Because the collection is not encrypted, the url in the info output is just the path appended to the base url.

$ dav info myserv/col/
 name: col
 path: /col
@@ -82,7 +82,7 @@
   getlastmodified: Wed, 14 Jun 2017 09:32:43 GMT
   supportedlock:

Example 2: encrypted resource

-

With encrypted resources, the path and url are different. The real resource name is random, but the name used by dav is stored in the crypto-name property.

+

With encrypted resources, the url in the info output looks different. The real resource name may be disguised, but the name used by dav is stored encrypted and base64 encoded in the crypto-name property. Read the encryption documentation to learn more about the davutils encryption feature.

$ dav info -c myserv/crres
 name: crres
 path: /crres
diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/list.html
--- a/docs/html/list.html	Sat Aug 05 11:33:17 2017 +0200
+++ b/docs/html/list.html	Sat Aug 05 13:35:27 2017 +0200
@@ -66,9 +66,9 @@
 

dav list

dav list [-altepcR] [-u <date>] <url>

-

Lists child resources of the specified collection. Without any options it shows only the direct children and hides files beginning with a dot.

+

Lists child resources of the specified collection. Without any option it shows only the direct children and hides files beginning with a dot. The behavior is quite similar to that of the unix tool ls.

Options

-

-a don't hide files whose names begins with a dot .

+

-a don't hide files whose names begin with a dot .

-l show additional information for resources

Example:

--     4.2 KiB  Oct 11  2015  somefile
@@ -77,20 +77,23 @@
  • Field: d- indicates a collection
  • Field: -c indicates an encrypted resource
  • -

    Also encrypted collections are possible, but only the collection name is encrypted, the content may be unencrypted.

    +

    Encrypted collections are also possible, but only the collection name is encrypted, the content may be unencrypted.

    The second column in the list -l output is the resource size. The number has always a suffix (bytes, KiB, MiB, GiB, TiB). To get the exact content-length in bytes you can use the dav info command.

    -

    The third column is the date of the last modification. The strftime format is %b %d %H:%M if the year is the same. Otherwise the format is %b %d %Y.

    +

    The third column is the date of the last modification. The strftime format is %b %d %H:%M if the year is the current year. Otherwise the format is %b %d %Y.

    The last column is the resource name. If the -R option is specified, the resource path is shown.

    -t this options only works in combination with -l and it adds the resource content type to the output (after the flags)

    -e similar to -l, but with 6 flag fields. Currently only the first 4 fields are used. The last two are reserved for future use.

    -
      -
    1. Field: l indicates a locked resource
    2. -
    3. Field: x indicates a executable resource (executable property with http://apache.org/dav/props/ namespace)
    4. +
        +
      1. Field: d--- indicates a collection
      2. +
      3. Field: -c-- indicates an encrypted resource
      4. +
      5. Field: --l- indicates a locked resource
      6. +
      7. Field: ---x indicates an executable resource (executable property with http://apache.org/dav/props/ namespace)
      +

      All combinations of these four flags are possible.

      -p disable file name and path decryption if enabled

      -c enable file name and path decryption

      -R recursively show all resources in the collection and all child collections

      -

      -u <date> show only resources with a lastmodified date after the specified date. Uses the http date format

      +

      -u <date> show only resources with a lastmodified date after the specified date. Uses the HTTP date format.

      Command alias: ls

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/lock.html --- a/docs/html/lock.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/lock.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,8 +66,8 @@

    dav lock

    lock [-pc] <url>

    -

    Creates a lock on the resource specified by the url. The lock is an exclusive write lock with infinity depth.

    -

    If the resource is successfully locked, a lock token for this resource is printed on stdout. This lock token should be saved somewhere to unlock the resource eventually.

    +

    Creates a lock on the resource specified by the url. The lock is an exclusive write lock with infinite depth.

    +

    If the resource is successfully locked, a lock token for this resource is printed to stdout. This lock token should be saved somewhere to unlock the resource eventually.

    -p disable file name and path decryption if enabled

    -c enable file name and path decryption

    Example 1: lock resource and use the lock token

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/mkdir.html --- a/docs/html/mkdir.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/mkdir.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,9 +66,9 @@

    dav mkdir

    mkdir [-pc] [-k <key>] [-L <lock>] <url>

    -

    Creates a collection. All intermediate collections are created.

    +

    Creates a collection. All intermediate collections are also created as necessary.

    -p disable file name encryption and decryption

    -

    -c enables file file name and content encryption

    +

    -c enable file file name and content encryption

    -k <key> use the specified key for encryption. The key must be configured in the config.xml file

    -L <lock> use a lock token

    Command alias: mkcol

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/move.html --- a/docs/html/move.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/move.html Sat Aug 05 13:35:27 2017 +0200 @@ -68,10 +68,10 @@

    move [-pcO] [-L <lock>] <url> <url>

    Moves the resource identified by url1 to the location url2. Currently url1 and url2 must be on the same host.

    If url2 already exists, the command aborts, unless the -O option is specified.

    -

    The command uses a single WebDAV MOVE request to move the resources. It does not handle the dav encryption functionality, which means it does not modify url2 if encryption is enabled.

    -

    -p disable file name and path decryption if enabled. This applies only to url1

    -

    -c enable file name and path decryption This applies only to url1

    -

    -O override the destination resource

    +

    The command uses a single WebDAV MOVE request to move the resources. You may use file name and path decryption to copy and encrypted resource. Please note that the target location will be exactly url2, so the top most collection name will not be disguised. See [encryption][2] for more details on how encryption works.

    +

    -p disable file name and path decryption for url1

    +

    -c enable file name and path decryption for url1

    +

    -O overwrite the destination resource

    -L <lock> use a lock token. See dav lock

    Command alias: mv

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/pull.html --- a/docs/html/pull.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/pull.html Sat Aug 05 13:35:27 2017 +0200 @@ -67,11 +67,11 @@

    dav-sync pull

    pull [-cld] <directory>

    Pulls all changes from the server. All new or modified files are downloaded and all files deleted on the server are deleted locally. If a file is also locally modified and conflict detection is not disabled, the local file is renamed and an entry in the conflict database is added.

    -

    When a trash directory is configured for the SyncDirectory, all files that should be deleted are moved to the trash directory.

    -

    When backup-on-pull is enabled for the SyncDirectory, all files that should be overridden are moved to the trash.

    -

    -c Disable conflict detection. This always overrides locally modified files

    +

    When a trash directory is configured for the SyncDirectory, all files that would be deleted are instead moved to the trash directory.

    +

    When backup-on-pull is enabled for the SyncDirectory, all files that would be overwritten are also moved to the trash.

    +

    -c Disable conflict detection. This always overwrites locally modified files

    -l Lock the repository before accessing it. After pull completed, the repository is unlocked

    -

    -d Don't lock the repository

    +

    -d Don't lock the repository (default)

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/push.html --- a/docs/html/push.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/push.html Sat Aug 05 13:35:27 2017 +0200 @@ -68,9 +68,9 @@

    push [-cld] <directory>

    Pushes all local changes to the server. This uploads all locally modified files and deletes all locally deleted files on the server.

    If conflict detection is not disabled, all files that are also modified on the server will be skipped.

    -

    -c Disable conflict detection. This always overrides files on the server

    +

    -c Disable conflict detection. This always overwrites files on the server

    -l Lock the repository before accessing it. After push completed, the repository is unlocked

    -

    -d Don't lock the repository

    +

    -d Don't lock the repository (default)

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/put.html --- a/docs/html/put.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/put.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,8 +66,8 @@

    dav put

    put [-pcR] [-k <key>] [-L <lock>] <url> <file>

    -

    Uploads a file or a directory. When uploading a file and the url points to an existing collection, a resource inside this collection with the file's name is created. When the url points to a non-existing resource, the resource is created.

    -

    When uploading a directory, you need to specify the -R option. It uploads all files in the directory to the specified url, but it does not create a collection for the directory itself.

    +

    Uploads a file or a directory. When uploading a file while the url points to an existing collection, a resource inside this collection with the file's name is created. When the url points to a non-existing resource, the resource is created.

    +

    When uploading a directory, you need to specify the -R option. It uploads all files in the directory to the specified url, but it does not create a collection for the directory itself. You may use dav mkdir to create this collection beforehand.

    -p disable file name encryption and decryption

    -c enable file name and content encryption

    -R upload directory

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/remove.html --- a/docs/html/remove.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/remove.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,7 +66,7 @@

    dav remove

    remove [-pc] [-L <lock>] <url>

    -

    Removes a resource. When removing a collection, all unterneath resources are removed.

    +

    Removes a resource. When removing a collection, all child resources are also removed.

    -p disable file name and path decryption if enabled

    -c enable file name and path decryption

    -L use a lock token

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/resolve-conflicts.html --- a/docs/html/resolve-conflicts.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/resolve-conflicts.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,7 +66,7 @@

    dav-sync resolve-conflicts

    resolve-conflicts <directory>

    -

    Removes conflict entries from the database. This does not merge any files. All files which are marked as conflict are normal files after running this command.

    +

    Removes conflict entries from the database. This does not merge any files. All files which are marked as conflict are normal files after running this command. In other words: by executing this command you assert that you have resolved the conflicts.

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/set-property.html --- a/docs/html/set-property.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/set-property.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,8 +66,8 @@

    dav set-property

    set-property [-pc] [-L <lock>] [-n <uri>] <url> <property> [value]

    -

    Sets a resource property to a specified value.

    -

    property is a property name with or without prefix (see get-property for details).

    +

    Sets a resource property to the specified value.

    +

    property is a property name with or without prefix (see get-property for details).

    If no value is specified, the content for the property is read from stdin.

    -p disable file name and path decryption if enabled

    -c enable file name and path decryption

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/trash-info.html --- a/docs/html/trash-info.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/trash-info.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,7 +66,7 @@

    dav-sync trash-info

    trash-info <directory>

    -

    Shows the trash directory path for a sync-directory, the number of files in there and the space consumption.

    +

    Shows the trash directory path for a sync-directory, the number of files currently in trash and the space they consume.

    diff -r ddb5e8f2a43d -r 3070d72f54af docs/html/unlock.html --- a/docs/html/unlock.html Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/html/unlock.html Sat Aug 05 13:35:27 2017 +0200 @@ -66,10 +66,10 @@

    dav unlock

    unlock [-pc] [-L <lock>] <url>

    -

    Unlocks the specified url with a lock token. If no lock token is specified with the -L option, it read from stdin.

    +

    Unlocks the specified url with a lock token. If no lock token is specified with the -L option, it read from stdin.

    -p disable file name and path decryption if enabled

    -c enable file name and path decryption

    -

    -L <lock> use a lock token

    +

    -L <lock> use the specified lock token

    Example 1: unlock with lock token from stdin

    $ dav lock myserv/resource > locktoken
     $ dav unlock myserv/resource < locktoken
    diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/copy.md --- a/docs/src/copy.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/copy.md Sat Aug 05 13:35:27 2017 +0200 @@ -18,7 +18,7 @@ **`-c`** enable file name and path decryption for *url1* -**`-O`** override the destination resource +**`-O`** overwrite the destination resource **`-L `** use a lock token. See [dav lock][1] diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/date.md --- a/docs/src/date.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/date.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,7 +3,7 @@ **`date [url]`** -The purpose of this command is to get the current date from a server and print it to stdout (HTTP date format). This in useful in combination with the `-U` option for the `list` and `get` command. +The purpose of this command is to get the current date from a server and print it to stdout (HTTP date format). This in useful in combination with the **`-u`** option for the `list` and `get` command. The *url* can be any http url. If no *url* is specified, the local time is used. @@ -17,7 +17,7 @@ After some resources are changed on the server, you can download only the modified files. - $ dav get -R -U `cat last_get` myserv/col/ + $ dav get -R -u `cat last_get` myserv/col/ diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/get-property.md --- a/docs/src/get-property.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/get-property.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,18 +3,18 @@ **`get-property [-pc] [-n ] `** -Gets a specified resource property. Every WebDAV property has a name and an XMl namespace. A namespace can be specified with the `-n` option or with a prefixed name. A prefix and property name are separated by an **:** +Gets a specific resource property. Every WebDAV property has a name and an XML namespace. A namespace can be specified with the `-n` option or with a prefixed name. The prefix and property name are separated by a **:** as usual. Example: `D:creationdate` `D` is the prefix, `creationdate` is the name. -There are only two available prefixes: +There are only two available prefixes by default: 1. `D` for the `DAV:` namespace 2. `idav` for `http://davutils.org/` -To use an other namespace, use the `-n` option. +To use another namespace, use the `-n` option. If the property name has no prefix, and no namespace is specified, the default namespace `DAV:` is used. diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/get.md --- a/docs/src/get.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/get.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,10 +3,10 @@ **`get [-pcR] [-o ] [-u ] `** -Downloads a resource. It can also download collections and its child resources. +Downloads a resource. This command also downloads collections and its child resources when the **`-R`** option is used. When downloading a single resource, the default local file name is the resource -name. When downloading collections, it does NOT create a local directory with -the collection's name and places it children in there, but it downloads the +name. When downloading collections, it does **not** create a local directory with +the collection's name and places its children in there, but it downloads the children directly to the current working directory. **`-p`** disable file name and content decryption. You get exactly what is stored @@ -18,6 +18,6 @@ **`-o `** specify the local output file. A **-** indicates stdout -**`-u `** download only files which are modified since the specified date. Uses the http date format +**`-u `** download only files which are modified since the specified date. Uses the HTTP date format diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/getting-started.md --- a/docs/src/getting-started.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/getting-started.md Sat Aug 05 13:35:27 2017 +0200 @@ -7,11 +7,11 @@ dav list http://example.com/webdav/ -This lists all child resources of the specified collection. If you are unfamiliar to WebDAV terminology this means basically listing all files in a directory, similar to the ls unix tool. Infact you can also write dav ls instead of dav list and there is also a -l option like ls has one. +This lists all child resources of the specified collection. If you are unfamiliar to WebDAV terminology this means basically listing all files in a directory, similar to the ls unix tool. Actually you can also write `dav ls` instead of `dav list` and there is also an `-l` option similarly to the unix tool `ls`. ### Create a repository -All dav commands are expecting a url argument, but it may be a bit cumbersome to type a full url every time. But you can configure a repository in the dav configuration file ($HOME/.dav/config.xml) with the servers url, optional authentication information and other options. After that you can access a webdav server just with the repository name and an optional path. +All dav commands are expecting an url argument, but it may be a bit cumbersome to type a full url every time. But you can configure a repository in the dav configuration file ($HOME/.dav/config.xml) with the servers url, optional authentication information and other options. Afterwards you can access a webdav server just with the repository name and an optional path. So when you have created a repository with the name myserv and the url http://example.com/webdav/, you can just type diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/info.md --- a/docs/src/info.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/info.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,11 +3,11 @@ **`info [-pc] `** -Prints some information and lists all properties for the resource specified by url. +Prints some information and lists all properties for the resource specified by *url*. ### Example 1: info of a collection -In this example *myserv* is a configured repository with the base url *https://example.com/webdav/*. Because *col* is not encrypted, the *url* is just the *path* appended to base url. +In this example *myserv* is a configured repository with the base url *https://example.com/webdav/*. Because the collection is not encrypted, the *url* in the info output is just the *path* appended to the base url. $ dav info myserv/col/ name: col @@ -24,7 +24,8 @@ ### Example 2: encrypted resource -With encrypted resources, the *path* and *url* are different. The real resource name is random, but the name used by *dav* is stored in the *crypto-name* property. +With encrypted resources, the *url* in the info output looks different. The real resource name may be disguised, but the name used by *dav* is stored encrypted and base64 encoded in the *crypto-name* property. +Read the [encryption][1] documentation to learn more about the davutils encryption feature. $ dav info -c myserv/crres name: crres @@ -47,3 +48,6 @@ crypto-hash: fm4zstp/FevTs1aoUXc3+mqTmAf2Go+zQ34rSp8/ixDlGLQJXR74Je+WMl1zxZKbS/+5VwDhyZ9pT3gInsq2SA== crypto-key: mykey crypto-name: ZU+lZtFi3dprBz44714plYwfRnhyI/apYq46Sk/B6QU= + +[1]: ./encryption.html + diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/list.md --- a/docs/src/list.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/list.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,13 +3,14 @@ **`dav list [-altepcR] [-u ] `** -Lists child resources of the specified collection. Without any options it +Lists child resources of the specified collection. Without any option it shows only the direct children and hides files beginning with a dot. +The behavior is quite similar to that of the unix tool `ls`. Options ------- -**`-a`** don't hide files whose names begins with a dot `.` +**`-a`** don't hide files whose names begin with a dot `.` **`-l`** show additional information for resources @@ -22,13 +23,13 @@ 1. Field: `d-` indicates a collection 2. Field: `-c` indicates an encrypted resource -Also encrypted collections are possible, but only the collection name is encrypted, the content may be unencrypted. +Encrypted collections are also possible, but only the collection name is encrypted, the content may be unencrypted. The second column in the `list -l` output is the resource size. The number has always a suffix (bytes, KiB, MiB, GiB, TiB). To get the exact content-length in bytes you can use the [dav info][1] command. [1]: ./info.html -The third column is the date of the last modification. The `strftime` format is `%b %d %H:%M` if the year is the same. Otherwise the format is `%b %d %Y`. +The third column is the date of the last modification. The `strftime` format is `%b %d %H:%M` if the year is the current year. Otherwise the format is `%b %d %Y`. The last column is the resource name. If the `-R` option is specified, the resource path is shown. @@ -36,8 +37,12 @@ **`-e`** similar to `-l`, but with 6 flag fields. Currently only the first 4 fields are used. The last two are reserved for future use. -3. Field: **l** indicates a locked resource -4. Field: **x** indicates a executable resource (executable property with http://apache.org/dav/props/ namespace) +1. Field: `d---` indicates a collection +2. Field: `-c--` indicates an encrypted resource +3. Field: `--l-` indicates a locked resource +4. Field: `---x` indicates an executable resource (executable property with http://apache.org/dav/props/ namespace) + +All combinations of these four flags are possible. **`-p`** disable file name and path decryption if enabled @@ -45,7 +50,7 @@ **`-R`** recursively show all resources in the collection and all child collections -**`-u `** show only resources with a lastmodified date after the specified - date. Uses the http date format +**`-u `** show only resources with a `lastmodified` date after the specified + date. Uses the HTTP date format. **Command alias:** ls diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/lock.md --- a/docs/src/lock.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/lock.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,9 +3,9 @@ **`lock [-pc] `** -Creates a lock on the resource specified by the url. The lock is an exclusive write lock with infinity depth. +Creates a lock on the resource specified by the *url*. The lock is an exclusive write lock with infinite depth. -If the resource is successfully locked, a lock token for this resource is printed on stdout. This lock token should be saved somewhere to unlock the resource eventually. +If the resource is successfully locked, a lock token for this resource is printed to stdout. This lock token should be saved somewhere to unlock the resource eventually. **`-p`** disable file name and path decryption if enabled diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/mkdir.md --- a/docs/src/mkdir.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/mkdir.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,11 +3,11 @@ **`mkdir [-pc] [-k ] [-L ] `** -Creates a collection. All intermediate collections are created. +Creates a collection. All intermediate collections are also created as necessary. **`-p`** disable file name encryption and decryption -**`-c`** enables file file name and content encryption +**`-c`** enable file file name and content encryption **`-k `** use the specified key for encryption. The key must be configured in the config.xml file diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/move.md --- a/docs/src/move.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/move.md Sat Aug 05 13:35:27 2017 +0200 @@ -7,13 +7,16 @@ If *url2* already exists, the command aborts, unless the `-O` option is specified. -The command uses a single WebDAV MOVE request to move the resources. It does not handle the dav encryption functionality, which means it does not modify *url2* if encryption is enabled. - -**`-p`** disable file name and path decryption if enabled. This applies only to *url1* +The command uses a single WebDAV MOVE request to move the resources. +You may use file name and path decryption to copy and encrypted resource. +Please note that the target location will be exactly *url2*, so the top most collection name will not be disguised. +See [encryption][2] for more details on how encryption works. -**`-c`** enable file name and path decryption This applies only to *url1* +**`-p`** disable file name and path decryption for *url1* -**`-O`** override the destination resource +**`-c`** enable file name and path decryption for *url1* + +**`-O`** overwrite the destination resource **`-L `** use a lock token. See [dav lock][1] diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/pull.md --- a/docs/src/pull.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/pull.md Sat Aug 05 13:35:27 2017 +0200 @@ -5,14 +5,14 @@ Pulls all changes from the server. All new or modified files are downloaded and all files deleted on the server are deleted locally. If a file is also locally modified and conflict detection is not disabled, the local file is renamed and an entry in the conflict database is added. -When a trash directory is configured for the SyncDirectory, all files that should be deleted are moved to the trash directory. +When a trash directory is configured for the SyncDirectory, all files that would be deleted are instead moved to the trash directory. -When backup-on-pull is enabled for the SyncDirectory, all files that should be overridden are moved to the trash. +When backup-on-pull is enabled for the SyncDirectory, all files that would be overwritten are also moved to the trash. -**`-c`** Disable conflict detection. This always overrides locally modified files +**`-c`** Disable conflict detection. This always overwrites locally modified files **`-l`** Lock the repository before accessing it. After `pull` completed, the repository is unlocked -**`-d`** Don't lock the repository +**`-d`** Don't lock the repository (default) diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/push.md --- a/docs/src/push.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/push.md Sat Aug 05 13:35:27 2017 +0200 @@ -7,8 +7,9 @@ If conflict detection is not disabled, all files that are also modified on the server will be skipped. -**`-c`** Disable conflict detection. This always overrides files on the server +**`-c`** Disable conflict detection. This always overwrites files on the server **`-l`** Lock the repository before accessing it. After `push` completed, the repository is unlocked -**`-d`** Don't lock the repository +**`-d`** Don't lock the repository (default) + diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/put.md --- a/docs/src/put.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/put.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,13 +3,14 @@ **`put [-pcR] [-k ] [-L ] `** -Uploads a file or a directory. When uploading a file and the url points to +Uploads a file or a directory. When uploading a file while the url points to an existing collection, a resource inside this collection with the file's name is created. When the url points to a non-existing resource, the resource is created. -When uploading a directory, you need to specify the -R option. It uploads +When uploading a directory, you need to specify the **`-R`** option. It uploads all files in the directory to the specified url, but it does not create a collection for the directory itself. +You may use [dav mkdir][1] to create this collection beforehand. **`-p`** disable file name encryption and decryption @@ -20,8 +21,9 @@ **`-k `** use the specified key for encryption. The key must be configured in the config.xml file -**`-L `** use a lock token. See [dav lock][1] +**`-L `** use a lock token. See [dav lock][2] -[1]: ./lock.html +[1]: ./mkdir.html +[2]: ./lock.html diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/remove.md --- a/docs/src/remove.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/remove.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,7 +3,7 @@ **`remove [-pc] [-L ] `** -Removes a resource. When removing a collection, all unterneath resources are +Removes a resource. When removing a collection, all child resources are also removed. **`-p`** disable file name and path decryption if enabled @@ -13,3 +13,4 @@ **`-L`** use a lock token **Command aliases:** rm, delete + diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/resolve-conflicts.md --- a/docs/src/resolve-conflicts.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/resolve-conflicts.md Sat Aug 05 13:35:27 2017 +0200 @@ -4,4 +4,5 @@ **`resolve-conflicts `** Removes conflict entries from the database. This does not merge any files. All files which are marked as conflict are normal files after running this command. +In other words: by executing this command you assert that *you* have resolved the conflicts. diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/set-property.md --- a/docs/src/set-property.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/set-property.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,9 +3,9 @@ **`set-property [-pc] [-L ] [-n ] [value]`** -Sets a resource property to a specified value. +Sets a resource property to the specified value. -property is a property name with or without prefix (see [get-property][1] for details). +*property* is a property name with or without prefix (see [get-property][1] for details). [1]: ./get-property.html diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/trash-info.md --- a/docs/src/trash-info.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/trash-info.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,4 +3,5 @@ **`trash-info `** -Shows the trash directory path for a sync-directory, the number of files in there and the space consumption. +Shows the trash directory path for a sync-directory, the number of files currently in trash and the space they consume. + diff -r ddb5e8f2a43d -r 3070d72f54af docs/src/unlock.md --- a/docs/src/unlock.md Sat Aug 05 11:33:17 2017 +0200 +++ b/docs/src/unlock.md Sat Aug 05 13:35:27 2017 +0200 @@ -3,13 +3,13 @@ **`unlock [-pc] [-L ] `** -Unlocks the specified url with a lock token. If no lock token is specified with the `-L` option, it read from stdin. +Unlocks the specified *url* with a lock token. If no lock token is specified with the `-L` option, it read from stdin. **`-p`** disable file name and path decryption if enabled **`-c`** enable file name and path decryption -**`-L `** use a lock token +**`-L `** use the specified lock token ### Example 1: unlock with lock token from stdin