Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

arsenal1130

macrumors newbie
Original poster
Mar 26, 2016
2
0
During my install of homebrew I believe I may have moved my bash profile and I'd like to return it back to its default. Any information would be greatly appreciated.

Ex:

JB:~ JR$ cat ~/.profile
cat: /Users/JB/.profile: No such file or directory



Thank you!
 

dyn

macrumors 68030
Aug 8, 2009
2,708
388
.nl
You could copy the one in /etc/profile or /etc/bashrc and alter the copied one to your liking (be sure to name it .bash_profile). If you make Time Machine backups you could retrieved it via that way. Best is to do that via the commandline.
 

chown33

Moderator
Staff member
Aug 9, 2009
10,999
8,887
A sea of green
Your thread title says ".bash_profile", but the command you posted refers to ".profile". Those are two different files.

If you have a ".bash_profile", then ".profile" isn't used, and vice versa.

What does this output?
Code:
/bin/cat ~/.bash_profile
How about this?
Code:
/bin/ls -la ~


Also, if your PATH is messed up, you need to show us what it is, by posting the output of this:
Code:
echo " $PATH"

The PATH is currently working well enough to find the 'cat' command. You can tell this by the form of the error message. It starts with the command-name ("cat:"), and then it tells you the file that doesn't exist.

If the problem were that 'cat' isn't being found due to a messed up PATH, the error message would be different. Try the command 'meow' insted of 'cat' and compare what it says with the message posted.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.