mirror of
https://github.com/sbrl/bin.git
synced 2018-01-10 21:33:46 +00:00
Added transfer
This commit is contained in:
parent
b791c982e0
commit
a030929c39
2 changed files with 11 additions and 0 deletions
|
@ -20,6 +20,9 @@ alias chmod='chmod -c'
|
|||
alias chown='chown -c'
|
||||
alias chgrp='chgrp -c'
|
||||
|
||||
# Make time work properly
|
||||
alias time=/usr/bin/time
|
||||
|
||||
# catz: gunzip & display commpressed gz files.
|
||||
alias catz='gunzip -c'
|
||||
|
||||
|
@ -42,6 +45,13 @@ alias hrh='hr - - = - -'
|
|||
alias sbrlbin='netcat starbeamrainbowlabs.com 9999'
|
||||
alias termbin='netcat termbin.com 9999'
|
||||
|
||||
# termbin for any kind of file
|
||||
transfer() { if [ $# -eq 0 ]; then echo "No arguments specified. Usage:\necho transfer /tmp/test.md\ncat /tmp/test.md | transfer test.md"; return 1; fi
|
||||
tmpfile=$( mktemp -t transferXXX ); if tty -s; then basefile=$(basename "$1" | sed -e 's/[^a-zA-Z0-9._-]/-/g'); curl --progress-bar --upload-file "$1" "https://transfer.sh/$basefile" >> $tmpfile; else curl --progress-bar --upload-file "-" "https://transfer.sh/$1" >> $tmpfile ; fi; cat $tmpfile; rm -f $tmpfile; }
|
||||
|
||||
# Get / Set clipboard contents
|
||||
alias setclip='xclip -selection c'
|
||||
alias getclip='xclip -selection clipboard -o'
|
||||
|
||||
# Ubuntu's inbuilt image previewer. I'll never be able to remember eog...
|
||||
alias image-preview=eog
|
||||
|
|
|
@ -21,6 +21,7 @@ Here's a list of the most interesting ones, along with what they do and where th
|
|||
- [speedtest-cli](https://github.com/sivel/speedtest-cli)
|
||||
- mountunishares - A script that automatically mounts my university file shares.
|
||||
- pd - A directory stack helper. Insanely useful - I think I picked it up from a superuser answer somewhere.
|
||||
- [transfer](https://transfer.sh/) - A look that looks very useful. Like termbin.com, but for any kind of file. Keeps files for 14 days, and has an uppder limit of 5GB.
|
||||
|
||||
## Disclaimer
|
||||
I don't own many of the tools in this repository. If you are an owner of one of these tools and I haven't linked to you, please let me know as I probably forgot.
|
||||
|
|
Loading…
Reference in a new issue