jay*_*jay 7 macos terminal .bash-profile
我在我的Mac OS X上向我的.bash_profile添加了一些内容,但是它们给出了错误.现在,当我启动终端时,这是我的整个文本日志:
Last login: Thu Oct 25 23:10:03 on ttys000
dirname: illegal option -- b
usage: dirname path
-bash: /bin/naoqi-bin: No such file or directory
-bash: exec: /bin/naoqi-bin: cannot execute: No such file or directory
[Process completed]
Run Code Online (Sandbox Code Playgroud)
问题是,由于"过程完成",我无法使用终端.我如何访问.bash_profile(我无法找到如何从finder中找到),或者如何再次正常运行终端以便我可以从.bash_profile文件中获取它?
nne*_*neo 16
打开Terminal,然后去File (or Shell) -> New Command.键入open -e .profile(或替换其他文件而不是.profile),然后单击"运行".这应该打开TextEdit与你想要修复的文件; 你可以删除那里的违规行.
为了完整起见,这是另一种方式:打开TextEdit(或您最喜欢的GUI文本编辑器).在打开的对话框中,按Command- Shift- Period,它将显示(并打开)不可见的文件,例如.profile.删除违规行,保存,你应该好好去.