Skip to content

Commit

Permalink
install: _bash-it-install-modify-profile()
Browse files Browse the repository at this point in the history
  • Loading branch information
gaelicWizard committed Jan 30, 2022
1 parent 99e4afa commit d718669
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,10 @@ function _bash-it-install-modify-config() {
# backup/new by default
_bash-it-install-backup-new
fi
_bash-it-install-modify-profile
}

function _bash-it-install-modify-profile() {
local choice profile_string=$'if [[ -s ~/.profile ]]; then\n\tsource ~/.profile\nfi\nif [[ $- == *"i"* && -s ~/.bashrc ]]; then\n\tsource ~/.bashrc\nfi'
if [[ ! -f ~/.bash_profile ]]; then
printf '%s\n' "${profile_string}" > ~/.bash_profile
Expand Down

0 comments on commit d718669

Please sign in to comment.