From d12ded88f4598fd3de3685872f3ebb320d992804 Mon Sep 17 00:00:00 2001 From: Andrew Coleman Date: Tue, 11 May 2021 12:28:44 -0400 Subject: [PATCH] hide shellcheck warnings --- dot_bashrc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/dot_bashrc b/dot_bashrc index 784441c..9b8f2f0 100644 --- a/dot_bashrc +++ b/dot_bashrc @@ -1,11 +1,14 @@ # If not running interactively, don't do anything [[ $- != *i* ]] && return +# shellcheck disable=SC2164 if [ "$PWD" != "$HOME" ] && [ "$PWD" -ef "$HOME" ] ; then cd ; fi +# shellcheck disable=SC2164 if [ -d "/usr$HOME" ] ; then export HOME=/usr$HOME ; cd ; fi for BASHRC in /etc/bashrc /etc/bash.bashrc /etc/bash/bashrc ; do if [ -f "$BASHRC" ] ; then + # shellcheck source=/dev/null . "$BASHRC" fi done @@ -13,7 +16,7 @@ unset BASHRC EDITOR=nvim; export EDITOR -if ! [[ "$PATH" =~ "$HOME/.local/bin:$HOME/bin:" ]] +if ! [[ "$PATH" =~ $HOME/.local/bin:$HOME/bin: ]] then PATH="$HOME/.local/bin:$HOME/bin:$PATH" fi @@ -23,6 +26,7 @@ export PATH if [ -d ~/.bashrc.d ]; then for rc in ~/.bashrc.d/*; do if [ -f "$rc" ]; then + # shellcheck source=/dev/null . "$rc" fi done