summaryrefslogtreecommitdiff
path: root/.config/shell/aliasrc
diff options
context:
space:
mode:
authorGustaf Rydholm <gustaf.rydholm@gmail.com>2021-05-23 20:51:42 +0200
committerGustaf Rydholm <gustaf.rydholm@gmail.com>2021-05-23 20:51:42 +0200
commit38c1296c06fa2c9948c2de1c3b5581d9b5e96105 (patch)
tree5ec54e47b6cd7634d7477db1d89bfe3b4a45ec53 /.config/shell/aliasrc
parentfa06e9e7f3fb49484ea1fa8f564816b548222e39 (diff)
Copying Luke Smith's config a lot
Diffstat (limited to '.config/shell/aliasrc')
-rwxr-xr-x.config/shell/aliasrc27
1 files changed, 27 insertions, 0 deletions
diff --git a/.config/shell/aliasrc b/.config/shell/aliasrc
new file mode 100755
index 0000000..8d4eacd
--- /dev/null
+++ b/.config/shell/aliasrc
@@ -0,0 +1,27 @@
+#!/bin/sh
+
+# Use neovim for vim if present.
+[ -x "$(command -v nvim)" ] && alias vim="nvim" vimdiff="nvim -d"
+
+# Use XINITRC variable if file exists.
+[ -f "$XINITRC" ] && alias startx="startx $XINITRC"
+
+# sudo not required for some system commands.
+for x in mount unmount sv pacman updatedb su ; do
+ alias $x="sudo $x"
+done
+
+# Verbosity and settings that you pretty much just always are going to want.
+alias \
+ cp="cp -iv" \
+ mv="mv -iv" \
+ rm="rm -vI" \
+ bc="bc -ql" \
+ mkd="mkdir -pv" \
+ ffmpeg="ffmpeg -hide_banner"
+
+alias \
+ ls="ls -hN --color=auto --group-directories-first" \
+ grep="grep --color=auto" \
+ diff="diff --color=auto" \
+ ccat="highlight --out-format=ansi"