4

I'm not quite ready for Bash-it and would like to go back to the original CLI. Any advice on how to remove Bash-it would be awesome. Thank you.

Edit: Would love to know why I'm getting down voted so I don't make the same mistake twice.

nwinkler
  • 52,665
  • 21
  • 154
  • 168
Waymond
  • 239
  • 2
  • 5
  • 21
  • 1
    Is the difficulty with setting your teminal's default shell, or deleting bash_it? – Pippin Nov 30 '13 at 04:57
  • 1
    Deleting bash_it. When I did delete the .bash_it folder, I got: -bash: /Users/waymond/.bash_it/bash_it.sh: No such file or directory way-MacBook-Pro:~ waymond1$ – Waymond Nov 30 '13 at 05:00
  • 1
    In your /Users/waymond/.bash_it/ directory are there any other files currently? – Pippin Nov 30 '13 at 05:02
  • 1
    There is not. Btw, thanks for the replies. – Waymond Nov 30 '13 at 05:05
  • 1
    No worries. Can you confirm that just typing 'bash' into terminal will switch you to your bash shell, which is the default. – Pippin Nov 30 '13 at 05:10
  • Yes, it goes to bash. – Waymond Nov 30 '13 at 05:12
  • What are you using to delete the folder? rm -rf /Users/waymond/.bash_it ? – Pippin Nov 30 '13 at 05:24
  • I did not. I deleted it a noob way but restored it. Is rm -rf /Users/waymond/.bash_it the correct way to remove it? – Waymond Nov 30 '13 at 05:43
  • Down votes are probably because this is not a programming question and belongs on [superuser.com](http://superuser.com/) or [Ask Different](http://apple.stackexchange.com/) – greg-449 Nov 30 '13 at 08:07

3 Answers3

9

I wanted to do the same thing. Here's a link to removing bash-it:

https://github.com/revans/bash-it/issues/161

I found it by going to the 'Issues' tab on the GitHub repository and then selecting 'Closed' issues.

I used this list of commands from my home directory:

ls -1a

This shows the list of files in the directory, including hidden files. You should see these in the list:

  • .bash-it (the directory you'll delete)
  • .bash_profile (your current bash profile)
  • .bash_profile.bak (your bash profile before installing bash-it)
sudo rm -rf .bash_it

This removes the bash-it directory. You'll be prompted for your password.

mv .bash_profile.bak .bash_profile

This overwrites the bash profile created by bash-it with your original bash profile.

ls -1a

You should now only see this file from the list above:

  • .bash_profile

Then restart your terminal.

nwinkler
  • 52,665
  • 21
  • 154
  • 168
Jonathan Mundy
  • 131
  • 1
  • 4
4

Bash-it now has an uninstall script. To uninstall Bash-it, do the following:

# CD into the Bash-it directory
cd $BASH_IT

# Make sure you have the latest version that includes the uninstall script
git pull origin master

# Run the uninstall script
./uninstall.sh

# Remove the ~/.bash_it folder
cd ..
rm -rf $BASH_IT

# Now close this shell and open a new one

The uninstall script will try to restore your previous Bash configuration file (.bash_profile on Mac OS X, .bashrc on Linux).

Once you have run the uninstall script, simply open a new shell and Bash-it shouldn't be used anymore.

nwinkler
  • 52,665
  • 21
  • 154
  • 168
2

To change default shell

System Preferences > Users & Groups > click the lock to make changes > right click (or Control click) on current user image > choose "Advanced Options"

You'll then see an option that will allow you to change the default shell. Once you reset the shell it it will change to the selected shell.

enter image description here

This can also be done in terminal with:

sudo chsh shell user

where shell is the shell you'd like to use (zsh,bash), and user in your case is waymond.

If you use iTerm, you'll also have further options for selecting the default shell depending on which shell you'd like to open in a new window. Command + , will get you to these preferences.

I'm not familiar with bash_it specifically as a shell and haven't found any explicit removal tools. Every shell spreads it branches slightly differently so it's tricky to follow another shells removal instructions -- for example Fish: source

Pippin
  • 1,066
  • 7
  • 15