[ADD][SHELL] Project-local environment w/ localrc
This little script will look at your current working directory and its parent directories to source local configuration files (very useful for Python projects, or the way I build TC with a local PATH pre-pended). It works relatively well but still is a very fragile solution that depends on the order in which the shell has sourced its files. Because the Termite script kept erasing the previous PROMPT_COMMAND value for Bash I had to change to source it at the beginning of my configuration file.
This commit is contained in:
parent
62ce5480bc
commit
67da1d9f6e
4 changed files with 137 additions and 17 deletions
16
bash/.bashrc
16
bash/.bashrc
|
|
@ -5,6 +5,14 @@
|
|||
# If not running interactively, don't do anything
|
||||
[[ $- != *i* ]] && return
|
||||
|
||||
# Export our directory to Termite for opening new terminals
|
||||
if [[ $TERM == xterm-termite ]]; then
|
||||
. /etc/profile.d/vte.sh
|
||||
__vte_prompt_command
|
||||
fi
|
||||
|
||||
[ -f ~/.fzf.bash ] && source ~/.fzf.bash
|
||||
|
||||
# Make colorcoding available for everyone
|
||||
|
||||
Black='\e[0;30m' # Black
|
||||
|
|
@ -54,11 +62,3 @@ source ~/.profile
|
|||
|
||||
# Import my prompt
|
||||
source ~/.bash_prompt
|
||||
|
||||
# Export our directory to Termite for opening new terminals
|
||||
if [[ $TERM == xterm-termite ]]; then
|
||||
. /etc/profile.d/vte.sh
|
||||
__vte_prompt_command
|
||||
fi
|
||||
|
||||
[ -f ~/.fzf.bash ] && source ~/.fzf.bash
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue