sharefile.sh: Se añade descripción de dependencias y de configuración
This commit is contained in:
parent
b7de63ef42
commit
ab9499ff79
|
@ -1,6 +1,20 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
#
|
#
|
||||||
# Dependencias: nnn, xsel
|
# Dependencias: nnn, preview-tabbed (plugin de nnn), xsel
|
||||||
|
# - nnn (https://github.com/jarun/nnn): gestor de archivos de terminal
|
||||||
|
# - preview-tabbed: previsualizador de archivos por pestañas/xembed
|
||||||
|
# - xsel (https://github.com/kfish/xsel): programa de línea de comandos para obtener y establecer
|
||||||
|
# el contenido de la selección X
|
||||||
|
#
|
||||||
|
# Cómo configurar el script:
|
||||||
|
# - Asegurarse de tener el plugin preview-tabbed en el directorio $HOME/.config/nnn/plugins
|
||||||
|
# (https://github.com/jarun/nnn/tree/master/plugins#list-of-plugins)
|
||||||
|
# - Configure la variable de entorno de acuerdo a como se indica en la wiki de nnn
|
||||||
|
# (https://github.com/jarun/nnn/tree/master/plugins#configuration)
|
||||||
|
# - Guarde este script en el path de ejecutables, por ejemplo en /usr/bin, /usr/local/bin,
|
||||||
|
# o en $HOME/.local/bin (si no existe este directorio, hay que crearlo)
|
||||||
|
# - Crear un atajo de teclado que para que ejecute este script
|
||||||
|
#
|
||||||
#
|
#
|
||||||
# Shell: POSIX compliant
|
# Shell: POSIX compliant
|
||||||
#
|
#
|
||||||
|
@ -29,12 +43,12 @@ case $1 in
|
||||||
|
|
||||||
# The Null Pointer Server
|
# The Null Pointer Server
|
||||||
--null)
|
--null)
|
||||||
curl -F "file=@$(nnn -P p -dQs irc -p -)" -F "secret=" https://0x0.st | xsel -b
|
curl -F "file=@$(nnn -P p -dQ -p -)" -F "secret=" https://0x0.st | xsel -b
|
||||||
;;
|
;;
|
||||||
|
|
||||||
# transfer.sh Server
|
# transfer.sh Server
|
||||||
--transfer)
|
--transfer)
|
||||||
files=$(nnn -P p -dQs irc -p -)
|
files=$(nnn -P p -dQ -p -)
|
||||||
curl --upload-file "$files" https://transfer.sh/"${files##/*}" | xsel -b
|
curl --upload-file "$files" https://transfer.sh/"${files##/*}" | xsel -b
|
||||||
;;
|
;;
|
||||||
-h|--help|*)
|
-h|--help|*)
|
||||||
|
|
Loading…
Reference in New Issue