thefuck
This commit is contained in:
parent
7768ba38be
commit
86f24dde3e
20
zsh/.zimrc
20
zsh/.zimrc
@ -47,7 +47,7 @@ zprompt_theme='steeef'
|
|||||||
#
|
#
|
||||||
|
|
||||||
# Set the string below to the desired terminal title format string.
|
# Set the string below to the desired terminal title format string.
|
||||||
# The terminal title is redrawn upon directory change, however, variables like
|
# The terminal title is redrawn upon directory change, however, variables like
|
||||||
# ${PWD} are only evaluated once. Use prompt expansion strings for dynamic data:
|
# ${PWD} are only evaluated once. Use prompt expansion strings for dynamic data:
|
||||||
# http://zsh.sourceforge.net/Doc/Release/Prompt-Expansion.html#Simple-Prompt-Escapes
|
# http://zsh.sourceforge.net/Doc/Release/Prompt-Expansion.html#Simple-Prompt-Escapes
|
||||||
# The example below uses the following format: 'username@host:/current/directory'
|
# The example below uses the following format: 'username@host:/current/directory'
|
||||||
@ -192,6 +192,22 @@ alias -g tb="nc termbin.com 9999 | xclip -selection clipboard"
|
|||||||
alias -g sshot='xfce4-screenshooter -o "$(which xclip) -i -t image/png -selection clipboard" $@'
|
alias -g sshot='xfce4-screenshooter -o "$(which xclip) -i -t image/png -selection clipboard" $@'
|
||||||
alias -g steam-wine='WINEDEBUG=-all wine ~/.wine/drive_c/Program\ Files\ \(x86\)/Steam/Steam.exe -no-cef-sandbox >/dev/null 2>&1 &'
|
alias -g steam-wine='WINEDEBUG=-all wine ~/.wine/drive_c/Program\ Files\ \(x86\)/Steam/Steam.exe -no-cef-sandbox >/dev/null 2>&1 &'
|
||||||
|
|
||||||
|
# thefuck
|
||||||
|
fuck () {
|
||||||
|
TF_PYTHONIOENCODING=$PYTHONIOENCODING;
|
||||||
|
export TF_SHELL=zsh;
|
||||||
|
export TF_ALIAS=fuck;
|
||||||
|
export TF_SHELL_ALIASES=$(alias);
|
||||||
|
export TF_HISTORY="$(fc -ln -10)";
|
||||||
|
export PYTHONIOENCODING=utf-8;
|
||||||
|
TF_CMD=$(
|
||||||
|
thefuck THEFUCK_ARGUMENT_PLACEHOLDER $@
|
||||||
|
) && eval $TF_CMD;
|
||||||
|
unset TF_HISTORY;
|
||||||
|
export PYTHONIOENCODING=$TF_PYTHONIOENCODING;
|
||||||
|
test -n "$TF_CMD" && print -s $TF_CMD
|
||||||
|
}
|
||||||
|
|
||||||
# Set (optional) pacman front-end.
|
# Set (optional) pacman front-end.
|
||||||
# zpacman_frontend='powerpill'
|
# zpacman_frontend='powerpill'
|
||||||
|
|
||||||
@ -201,4 +217,4 @@ export VISUAL="vim"
|
|||||||
export PATH=/usr/local/texlive/2016/bin/x86_64-linux:$PATH
|
export PATH=/usr/local/texlive/2016/bin/x86_64-linux:$PATH
|
||||||
# If not running interactively, do not do anything
|
# If not running interactively, do not do anything
|
||||||
[[ $- != *i* ]] && return
|
[[ $- != *i* ]] && return
|
||||||
[[ -z "$TMUX" ]] && exec tmux -u
|
[[ -z "$TMUX" ]] && exec tmux -u
|
||||||
|
Loading…
Reference in New Issue
Block a user