mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-01-02 02:19:06 +01:00
tiny sprunge update
This commit is contained in:
parent
6c9ad747b1
commit
f7ff6b6439
2 changed files with 3 additions and 3 deletions
|
|
@ -1,4 +1,4 @@
|
||||||
setopt correct_all
|
#setopt correct_all
|
||||||
|
|
||||||
alias man='nocorrect man'
|
alias man='nocorrect man'
|
||||||
alias mv='nocorrect mv'
|
alias mv='nocorrect mv'
|
||||||
|
|
|
||||||
|
|
@ -43,7 +43,7 @@ sprunge() {
|
||||||
# read from stdin
|
# read from stdin
|
||||||
url=$(curl -s -F 'sprunge=<-' http://sprunge.us <& 0)
|
url=$(curl -s -F 'sprunge=<-' http://sprunge.us <& 0)
|
||||||
urls=(${url//[[:space:]]})
|
urls=(${url//[[:space:]]})
|
||||||
echo "stdin: $url" >> $OMZ/sprunge.log
|
[[ -z $url ]] || echo "stdin\t$url" >> $OMZ/sprunge.log
|
||||||
else
|
else
|
||||||
# treat arguments as a list of files to upload
|
# treat arguments as a list of files to upload
|
||||||
for file in $@; do
|
for file in $@; do
|
||||||
|
|
@ -57,7 +57,7 @@ sprunge() {
|
||||||
url=${url//[[:space:]]}
|
url=${url//[[:space:]]}
|
||||||
[[ $syntax != text ]] && url=${url}?${syntax}
|
[[ $syntax != text ]] && url=${url}?${syntax}
|
||||||
|
|
||||||
echo "$file: $url" >> $OMZ/sprunge.log
|
[[ -z $url ]] || echo "$file\t$url" >> $OMZ/sprunge.log
|
||||||
urls+=(${url})
|
urls+=(${url})
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue