mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2025-12-26 02:12:33 +01:00
sprunge command has a setting!
This commit is contained in:
parent
de3c49c38d
commit
d973665df0
1 changed files with 13 additions and 4 deletions
|
|
@ -1,8 +1,17 @@
|
|||
# A simple alias for sprunge, but only if there isn't a smarter, better one out
|
||||
# there in $PATH
|
||||
# Smart sprunge alias/script.
|
||||
#
|
||||
# A good one to add is the sprunge script in this directory.
|
||||
# To add the sprunge script to your path, add this to your .zshrc file:
|
||||
#
|
||||
# zstyle :omz:plugins:sprunge add-path on
|
||||
#
|
||||
# Otherwise, a simple alias for sprunge, but only if there isn't a smarter,
|
||||
# better one out there in $PATH, will be added.
|
||||
|
||||
if [ -z "${commands[sprunge]}" ]; then
|
||||
zstyle -b :omz:plugins:sprunge add-path _plugin__path
|
||||
if [[ ${_plugin__path} == "on" ]]; then
|
||||
# Plugin setting: Add this plugin directory to the path
|
||||
export PATH=$PATH:$ZSH/plugins/sprunge
|
||||
elif [ -z "${commands[sprunge]}" ]; then
|
||||
# Nope. No `sprunge` command, period. So, dumb/simple alias, here we go!
|
||||
alias sprunge="curl -F 'sprunge=<-' http://sprunge.us/"
|
||||
fi
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue