aboutsummaryrefslogtreecommitdiffstats
path: root/util/zotsh/README.txt
blob: 58e8d4bd0df089021371aca4b62290c5fe4e0af9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
ZotSH - v.0.0.2

Client for browsing RedDAVs.

Install
-------

ZotSH requires 'requests'(1).
Please refer to requests docs on how to install it (2)

The initially connected server must have the twitter_api plugin installed

Extract somewere and launch zotsh.py


Description
-----------

Update: 2019-08-14

Have just looked at this after several years of bitrot and made some updates.
it functions for cli DAV access on your assigned hub, but magic-auth to dav repos on other hubs
(e.g. the host command) needs to be updated to work with openwebauth.

----
ZotSH is a command line WebDAV client for Hubzilla.
It knows how to magic-auth to remote hubs using Zot.

ZotSH uses 'easywebdav' library (0) with small modifications
to 'zotify' it. (See easywebdav/LICENSE)



Commands
--------

host <hostname>
	Authenticate to 'hostname' and switch to it

cd <dirname|..>
	changhe remote dir


ls [path] [-a] [-l] [-d]
	list remote files in current dir if 'path' not defined
	-a list all, show hidden dot-files
	-l list verbose
	-d list only dirs

exists <path>
	Check existence of 'path'
	
mkdir <name>
	Create directory 'name'

mkdirs <path>
	Create parent directories to path, if they don't exists

rmdir <name>
	Delete directory 'name'

delete <path>
	Delete file 'path'

upload <local_path> [remote_path]
	Upload local file 'local_paht' to 'remote_paht'

download <remote_path> [local_path]
	Download remote file 'remote_path' and save it as 'local_path'

cat <remote_paht>
	Print content of 'remote_path'

pwd
	Print current path

lcd
lpwd
lls
	Local file management

quit
help



Config
------

Create a .zotshrc file in your home or in same folder with zotsh.py:


	[zotsh]
	host = https://yourhost.com/
	username = your_username
	password = your_password


Optionally adds

        verify_ssl = false

to skip verification of ssl certs


Changelog
----------
0.0.2		Fix "CommandNotFound" exception, new 'cat' command

0.0.1		First release


Links
-----

_0 : https://github.com/amnong/easywebdav
_1 : http://docs.python-requests.org/en/latest/
_2 : http://docs.python-requests.org/en/latest/user/install/