feat(functiions): add fuck
This commit is contained in:
parent
719786d9ac
commit
85ac9a7fb4
2 changed files with 13 additions and 1 deletions
12
.zsh_functions/fuck.zsh
Normal file
12
.zsh_functions/fuck.zsh
Normal file
|
@ -0,0 +1,12 @@
|
|||
function fuck {
|
||||
local nth_last=${1:-1}
|
||||
if [[ "$nth_last" =~ ^[0-9]+$ ]]; then
|
||||
sudo $(fc -ln -$nth_last -$nth_last)
|
||||
else
|
||||
echo "Usage: fuck [offset]"
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
alias please='fuck'
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue