summaryrefslogtreecommitdiff
path: root/.config/zsh/halfway/aliases.zsh
diff options
context:
space:
mode:
authorA Farzat <a@farzat.xyz>2024-11-05 07:42:55 +0900
committerA Farzat <a@farzat.xyz>2024-11-13 07:42:55 +0900
commitcb5affa0e11c200f175e26ced4f2866aa916d2c9 (patch)
tree157d2d413b3e1090fecb9aeb06cd51b49040a2c9 /.config/zsh/halfway/aliases.zsh
parent6afb1f1eec5a8254635773f952fb6494f35a1933 (diff)
downloaddotfiles-cb5affa0e11c200f175e26ced4f2866aa916d2c9.tar.gz
dotfiles-cb5affa0e11c200f175e26ced4f2866aa916d2c9.zip
Remove zsh submodule
Zsh config will be included as bare files instead of a submodule. The zsh config repo will still exist, but the content will be used by yadm without the repo itself.
Diffstat (limited to '.config/zsh/halfway/aliases.zsh')
-rw-r--r--.config/zsh/halfway/aliases.zsh29
1 files changed, 29 insertions, 0 deletions
diff --git a/.config/zsh/halfway/aliases.zsh b/.config/zsh/halfway/aliases.zsh
new file mode 100644
index 0000000..fc7815f
--- /dev/null
+++ b/.config/zsh/halfway/aliases.zsh
@@ -0,0 +1,29 @@
+# Edit bash history.
+alias mbashhistory='${EDITOR:-nvim} ~/.bash_history'
+# Edit zsh history.
+alias mhistory='${EDITOR:-nvim} $ZDOTDIR/.zsh_history'
+# Edit and view using ${EDITOR:-nvim}.
+alias v='${EDITOR:-nvim}'
+alias edit='${EDITOR:-nvim}'
+alias view='${EDITOR:-nvim} -M'
+# Edit zshrc.
+alias mzshrc='${EDITOR:-nvim} -S "$ZDOTDIR/Session.vim"'
+# Edit ${EDITOR:-nvim} configuration files.
+alias mvimrc='${EDITOR:-nvim} -S "$XDG_CONFIG_HOME/nvim/Session.vim"'
+# List swap files
+alias ls-swap='la "${XDG_STATE_HOME:-$HOME/.local/state}/nvim/swap/"'
+# Edit the ledger file.
+alias mledger='${EDITOR:-nvim} -S $XDG_DATA_HOME/ledger/Session.vim'
+# Edit all files in git dir.
+alias vgit='git ls-files -z | xargs -0 ${EDITOR:-nvim}'
+# Suspend the machine.
+alias ssuspend='systemctl suspend'
+# Restore cursor to original colour and transparent behaviour before wal.
+alias restore_cursor="printf '%b' '\e]12'"
+# General.
+alias la='ls -lAh --color=auto'
+# Pacman categorize packages.
+alias pacman-orphan='pacman -Qtdq'
+alias pacman-explicit-native='pacman -Qneq'
+alias pacman-explicit='pacman -Qeq'
+alias pacman-optional='comm -3 <(pacman -Qttq | sort) <(pacman -Qtteq | sort)'