Misc. .bashrc tweaks
x1phosura x1phosura@x1phosura.zone
Tue, 20 Feb 2024 23:41:37 -0800
1 files changed,
4 insertions(+),
4 deletions(-)
jump to
M
.bashrc
→
.bashrc
@@ -27,7 +27,7 @@
case "$(uname -s)" in # for OS-specific configuration Linux) operating_system='linux' ;; Darwin) operating_system='macOS' ;; - FreeBSD|OpenBSD|NetBSD) operating_system='BSD' ;; + FreeBSD|OpenBSD|NetBSD) operating_system='BSD' ;; CYGWIN*|MINGW32*|MSYS*|MINGW*) operating_system='windows' ;; *) operating_system='other' ;; esac@@ -250,7 +250,7 @@
sync-src-to-dest() { if [ ! "$#" = 2 ]; then echo "A useful rsync helper, semi-unsafe if used thoughtlessly" - echo "usage: $0 [src-dir/] [dest-dir/]" + echo "usage: sync-src-to-dest [src-dir/] [dest-dir/]" return 1 fi@@ -333,7 +333,7 @@
[ "$operating_system" = "linux" ] && alias spellcheck='aspell check ' case "$operating_system" in - macOS) color_flag='-C ' ;; + macOS) color_flag='-C ' ;; BSD) color_flag='--color=auto ' ;; linux) color_flag='--color=auto ' ;; *) color_flag='--color=auto ' ;; # assume GNU ls@@ -374,7 +374,7 @@
#complete -cf sudo # so sudo actually has tab autocompletion bind 'set completion-ignore-case on' # case-insensitive tab autocompletion -. "$HOME/.cargo/env" # should already be in .bash_profile, but just in case +[ -f "$HOME/.cargo/env" ] && source "$HOME/.cargo/env" # if not in .bash_profile # uncomment below to profile bashrc startup in /tmp/bashstart.SEC.NANOSEC #set -x