diff options
Diffstat (limited to 'bashrc/.bashrc')
| -rw-r--r-- | bashrc/.bashrc | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/bashrc/.bashrc b/bashrc/.bashrc new file mode 100644 index 0000000..f3dfc73 --- /dev/null +++ b/bashrc/.bashrc @@ -0,0 +1,18 @@ +# .bashrc + +# If not running interactively, don't do anything +[[ $- != *i* ]] && return + +alias ls='ls --color=auto' +alias code='code-oss' +alias xi='xbps-install' +export EDITOR='nvim' +PS1='[\u@\h \W]\$ ' + +function y() { + local tmp="$(mktemp -t "yazi-cwd.XXXXXX")" cwd + command yazi "$@" --cwd-file="$tmp" + IFS= read -r -d '' cwd < "$tmp" + [ "$cwd" != "$PWD" ] && [ -d "$cwd" ] && builtin cd -- "$cwd" + rm -f -- "$tmp" +} |
