Bash: few tweaks.
This commit is contained in:
parent
bf1caa5979
commit
9120b0d311
@ -102,6 +102,9 @@ gi() { grunt-init $@; }
|
|||||||
alias venv='test -d ENV && source ./ENV/bin/activate || echo "No Virtualenv in the current folder."'
|
alias venv='test -d ENV && source ./ENV/bin/activate || echo "No Virtualenv in the current folder."'
|
||||||
alias venv-init='test -d ENV && echo "Virtualenv already exists." || virtualenv --no-site-packages ENV; venv'
|
alias venv-init='test -d ENV && echo "Virtualenv already exists." || virtualenv --no-site-packages ENV; venv'
|
||||||
|
|
||||||
|
# Restart Linux service
|
||||||
|
rstr() { sudo service $@ restart }
|
||||||
|
|
||||||
# Magic Project Opener
|
# Magic Project Opener
|
||||||
function proj { cd "$("$HOME/dotfiles/bin/opener.py" "$HOME/Dropbox/Projects" $1 -w project $2)"; }
|
function proj { cd "$("$HOME/dotfiles/bin/opener.py" "$HOME/Dropbox/Projects" $1 -w project $2)"; }
|
||||||
function repo { cd "$("$HOME/dotfiles/bin/opener.py" "$HOME/Dropbox/Projects" $1 -w repo $2)"; }
|
function repo { cd "$("$HOME/dotfiles/bin/opener.py" "$HOME/Dropbox/Projects" $1 -w repo $2)"; }
|
||||||
|
@ -111,8 +111,7 @@ ssh-key() {
|
|||||||
ssh-keygen -t rsa
|
ssh-keygen -t rsa
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cat "$file" | c
|
cat "$file"
|
||||||
echo "Your public key copied to clipboard."
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# Create an SSH key and uploads it to the given host
|
# Create an SSH key and uploads it to the given host
|
||||||
@ -297,6 +296,6 @@ function sayit() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
# Add special aliases that will copy result to clipboard (escape → escape+)
|
# Add special aliases that will copy result to clipboard (escape → escape+)
|
||||||
for cmd in password hex2hsl hex2rgb escape codepoint; do
|
for cmd in password hex2hsl hex2rgb escape codepoint ssh-key; do
|
||||||
eval "function $cmd+() { $cmd \$@ | c; }"
|
eval "function $cmd+() { $cmd \$@ | c; }"
|
||||||
done
|
done
|
||||||
|
Loading…
Reference in New Issue
Block a user