Skip to content

Commit

Permalink
Showing 2 changed files with 32 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[bumpversion]
current_version = 0.1.98
current_version = 0.1.99
32 changes: 31 additions & 1 deletion shell/common.sh
Original file line number Diff line number Diff line change
@@ -4,6 +4,8 @@
# bat
if command -v bat >/dev/null 2>&1; then
alias cat='bat'
alias catp='bat --style=plain'
tf() { tail -f "$1" | bat --paging=never -l log; }
fi

# bottom
@@ -25,6 +27,20 @@ alias cddf='cd "${HOME}"/dotfiles'
alias cddl='cd "${HOME}"/Downloads'
alias cdw='cd "${HOME}"/work'

# chmod
chmod_files() {
find . -type f -exec chmod "$1" {} \;
}
chmod_dirs() {
find . -type d -exec chmod "$1" {} \;
}
chown_files() {
find . -type f -exec chown "$1" {} \;
}
chown_dirs() {
find . -type d -exec chown "$1" {} \;
}

# coverage
alias open-cov='open .coverage/html/index.html'

@@ -123,9 +139,12 @@ set editing-mode vi
# neovim
if command -v nvim >/dev/null 2>&1; then
alias n='nvim'
alias cdplugins='cd "${XDG_CONFIG_HOME:-${HOME}/.config}/nvim/plugins"'
alias cdplugins='cd "${XDG_CONFIG_HOME:-${HOME}/.config}/nvim/lua/custom/plugins"'
fi

# path
alias echo-path='sed '"'"'s/:/\n/g'"'"' <<< "${PATH}"'

# pip
alias pi='pip install'
alias pie='pip install --editable .'
@@ -142,12 +161,23 @@ if command -v pre-commit >/dev/null 2>&1; then
alias pci='pre-commit install'
fi

# ps
alias pst='ps -fLu "$USER"| wc -l'
if [ "$(command -v watch)" ]; then
alias wpst='watch -d -n0.1 "ps -fLu \"$USER\" | wc -l"'
fi

# pytest
__file="${HOME}"/dotfiles/pytest/aliases.sh
if [ -f "$__file" ]; then
. "$__file"
fi

# rm
alias rmr='rm -r'
alias rmf='rm -f'
alias rmrf='rm -rf'

# ruff
if command -v ruff >/dev/null 2>&1; then
alias rw='ruff check -w'

0 comments on commit 5fe4065

Please sign in to comment.