diff options
author | Tyler Davis <tydavis@gmail.com> | 2023-08-13 07:15:42 -0700 |
---|---|---|
committer | Tyler Davis <tydavis@gmail.com> | 2023-08-13 07:15:42 -0700 |
commit | 1375207cfb4d2f619e619d0a34a3640dae920b7b (patch) | |
tree | 6813282e52028219730b7998805d35c615e7ee56 /.profile | |
parent | e4a4da87d056c20fbfe4a279824fd4ae7936871d (diff) | |
download | dotfiles-1375207cfb4d2f619e619d0a34a3640dae920b7b.tar.gz dotfiles-1375207cfb4d2f619e619d0a34a3640dae920b7b.zip |
bash: small tweaks
Diffstat (limited to '.profile')
-rw-r--r-- | .profile | 16 |
1 files changed, 6 insertions, 10 deletions
@@ -22,17 +22,12 @@ if [ -f "$HOME/.cargo/env" ]; then fi # == Editors == -# Add in helix short command -if [ "$(command -v helix)" ]; then - alias hx='helix' -fi - # VSCode if [ "$(command -v code)" ]; then export EDITOR="code" export VISUAL="code" else - # Vim not detected? Use vi + # Vim not detected? Use vi as a fallback if [ ! "$(command -v vim)" ]; then alias vim=vi fi @@ -93,11 +88,10 @@ if [ "$(uname -s)" = "Darwin" ]; then # Make bash more posix compliant if [ $SHELL = "/bin/bash" ]; then set -o posix + # OSX-specific bash warning + export BASH_SILENCE_DEPRECATION_WARNING=1 fi - # OSX-specific bash warning - export BASH_SILENCE_DEPRECATION_WARNING=1 - # Brew (OSX) specifics if [ -f '/opt/homebrew/bin/brew' ]; then export HOMEBREW_PREFIX="/opt/homebrew" @@ -159,4 +153,6 @@ USER=$(id -un) HOSTNAME=$(uname -n) export PS1='$USER@$HOSTNAME:$PWD/\$ ' -if [ -f "$HOME/.bashrc" ]; then . $HOME/.bashrc; fi +if [ $SHELL = "/bin/bash" ]; then + if [ -f "$HOME/.bashrc" ]; then . $HOME/.bashrc; fi +fi |