.profile.common

Mon, 27 Mar 2023 15:27:23 -0500

author
Meredith Howard <mhoward@roomag.org>
date
Mon, 27 Mar 2023 15:27:23 -0500
changeset 1094
694fb6cd9cc2
parent 1067
08675f3a85f6
child 1103
0c1f1cf78ed9
permissions
-rw-r--r--

add nvim-treesitter-endwise

# vim: ft=bash
# simple profile stuff that is common to both zsh and bash

# most ssh versions support include now, see if i can...
make -s -C ~/.ssh || {
  umask 077
  cat ~/.ssh/config.d/* > ~/.ssh/config
}

umask 027

HISTIGNORE="ls:cd:cd -:pwd:exit:date:privim"

export MANPATH=$HOME/.man:$HOME/.local/share/man:

if [ -d ~/perl5/lib ]; then
  eval "$(perl -Mlocal::lib)"
fi

if [ -d /opt/homebrew ]; then
  eval "$(/opt/homebrew/bin/brew shellenv)"
fi

if [ -d ~/.asdf ]; then
  source ~/.asdf/asdf.sh
fi

if [ -x "$(command -v nvim)" ]; then
  export EDITOR=nvim
  alias vim=nvim
  alias view="nvim -R"
else
  export editor=vim
fi

export SUDO_EDITOR=$HOME/bin/privim
export LESS='Ri'
export GPG_TTY="$(tty)"

export PERL_CPANM_OPT='-nq --prompt'

export ASDF_CONCURRENCY='2'
export RUBY_EXTRA_CONFIGURE_OPTIONS="--enable-shared --enable-install-doc"

alias l='ls -lFh'     #size,show type,human readable
alias la='ls -lAFh'   #long list,show almost all,show type,human readable
alias lt='ls -ltFh'   #long list,sorted by date,show type,human readable
alias ll='ls -l'      #long list
alias rm='rm -i'
alias cp='cp -i'
alias mv='mv -i'

alias hgcd='cd $(hg root)'
alias gcd='cd "$(git rev-parse --show-toplevel)"'

vg() {
  $EDITOR +copen -q <(ag --vimgrep "${@:?No pattern provided.}")
}

alias tmux-env='eval "$(tmux show-environment -s)"'
alias :e=$EDITOR
alias :q=exit

if [ -f ~/.profile.common.local ]; then
  source ~/.profile.common.local
fi

mercurial