Skip to content

Commit

Permalink
cmd: readme was updated. closes #27
Browse files Browse the repository at this point in the history
Wrapper script section was updated
  • Loading branch information
MrVine committed Oct 22, 2018
1 parent 7493d8b commit 425530b
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions cmd/gowebdav/README.md
Expand Up @@ -76,10 +76,7 @@ gowebdav -X DEL temp/file.txt

# Wrapper script

Create a wrapper script for example `$EDITOR ./dav && chmod a+x ./dav` for your
server and use [pass](https://www.passwordstore.org/ "the standard unix password manager")
or similar tools to retrieve the password.

You can create wrapper script for your server (via `$EDITOR ./dav && chmod a+x ./dav`) and add following content to it:
```sh
#!/bin/sh

Expand All @@ -89,6 +86,8 @@ PASSWORD="$(pass dav/foo@my.dav.server)" \
gowebdav $@
```

It allows you to use [pass](https://www.passwordstore.org/ "the standard unix password manager") or similar tools to retrieve the password.

## Examples

Using the `dav` wrapper:
Expand All @@ -97,12 +96,8 @@ Using the `dav` wrapper:
$ ./dav -X LS /

$ echo hi dav! > hello && ./dav -X PUT /hello

$ ./dav -X STAT /hello

$ ./dav -X PUT /hello_dav hello

$ ./dav -X GET /hello_dav

$ ./dav -X GET /hello_dav hello.txt
```

0 comments on commit 425530b

Please sign in to comment.