1
0
Fork 0
mirror of https://github.com/notwa/rc synced 2024-11-05 03:19:02 -08:00

add comments and dummy docstrings

This commit is contained in:
Connor Olding 2021-07-31 16:15:27 -07:00
parent 831536107c
commit 1cc9a75b29
3 changed files with 11 additions and 10 deletions

View file

@ -1,4 +1,5 @@
#!/usr/bin/env sh
# backup, timestamped
# YES_ZSH
# YES_BASH
# YES_DASH

View file

@ -4,7 +4,7 @@
# YES_DASH
days() { ### @-
### compute days since a given date.
### compute the number of days since a given date.
###
### ```
### $ days 'January 1 1970'

18
sh/ea
View file

@ -8,36 +8,36 @@ _REMOTE_DOMAIN="https://eaguru.guru"
_REMOTE_DIR="t"
_REMOTE_AUTH="auth"
eahead() {
eahead() { ### @-
curl -s -I "$_REMOTE_DOMAIN/$_REMOTE_DIR/$1"
}
eaget() {
eaget() { ### @-
curl -R "$_REMOTE_DOMAIN/$_REMOTE_DIR/$1" -o "${2:-$1}"
}
eaput() {
eaput() { ### @-
curl -g -n -T "$1" "$_REMOTE_DOMAIN/$_REMOTE_AUTH/"
}
eamove() {
eamove() { ### @-
local src="$_REMOTE_DOMAIN/$_REMOTE_AUTH/$1"
local dst="$_REMOTE_DOMAIN/$_REMOTE_DIR/$2"
curl -n -X MOVE -H "Destination: $dst" "$src"
}
eacopy() {
eacopy() { ### @-
local src="$_REMOTE_DOMAIN/$_REMOTE_AUTH/$1"
local dst="$_REMOTE_DOMAIN/$_REMOTE_DIR/$2"
curl -n -X COPY -H "Destination: $dst" "$src"
}
eadelete() {
eadelete() { ### @-
curl -n -X DELETE "$_REMOTE_DOMAIN/$_REMOTE_AUTH/$1"
}
alias eamv=eamove
alias eacp=eacopy
alias earm=eadelete
alias eamv=eamove ### @-
alias eacp=eacopy ### @-
alias earm=eadelete ### @-
# TODO: write "ea" interface with subcommands for each action, invoke it.