I accidentally installed a zshrc script from this link https://gist.github.com/kevin-smets/8568070. But it completely ruined my current bash_profile and bashrc. I think it's using the zsh login shell on top of my terminal and iTerm. And now ,I have no idea on how to remove it.
I tried removing the com.company.iTerm.plist from preferences. But it still hasn't worked.
Any suggestions? I really need help.
Related
Can't find many resources on this. With Mac OS Catalina, the default shell switched from bash to zsh.
I want to edit .zshrc so I can add some ssh shortcuts (and avoid having to copy/paste my ssh command from a text file every morning). I can't find .zshrc anywhere. Do I have to create it? Am I headed in the wrong direction? Any help appreciated.
.zshrc should be under /Users/username/
Try ls -a in terminal if you haven't to show hidden files. If .zshrc isn't there, you need to make one.
I wanted to change the theme of my oh my zsh terminal in the .zshrc-file. When I tried to do that it didn't register and gave me an Error-message which I wasn't able to reproduce. Now I just have this weird Lock in my Terminal. Does somebody knows what it means / how I can get rid of it?
Zsh Terminal Screenshot
I was fooling around with .zshrc files, and now I am locked out of my terminal with "No such shell function 'accept-line'".
It would be easy to just go and undo the change in the .zshrc file, but my terminal autoloads into zsh, so there is no way to edit the dotfile.
I have looked all around for a way to edit hidden files in El Capitan, but to no avail.
From your mention of 'El Capitan' I infer that you might be on OS X and using Terminal.app? If so, please add a tag for that, or state that clearly.
If so, you could duplicate a Terminal profile in the preferences and under Settings->Shell / Startup set e.g. /bin/bash as the command and untick "run inside shell". That should give you a bash which will ignore .zshrc.
Otherwise, look for similar settings in your terminal emulator. Most should have such a setting somewhere.
I was upgrading everything in homebrew and zsh was upgrading and I was cycling through my open applications and accidentally closed iterm during the update. Now I can't open iterm and when I open the terminal I get the following error message:
login: /usr/local/bin/zsh: No such file or directory
I am not sure how I can switch back to bash until I correctly update zsh. I also can't type a single command in either iterm or termianl which makes sense (there's no zsh file). How can I finish upgrading zsh correctly or switch back to bash?
I have done a good amount of research and can't find someone having a similar issue.
Any guidance to how to solve this issue would be much appreciated, I currently can't do any of the development work I need to do.
Found this on Apple's suport site. Basically, you want to launch Terminal and go into Preferences. Change Shells open with from Default login shell to a valid shell (I recommend /bin/bash or even /bin/sh just to get you working again).
Once you can access your shell session, you can restore zsh.
Here's the full article... http://support.apple.com/kb/ta27005
I can't seem to change the default bash editor in OSX Lion terminal.
I've tried setting:
export EDITOR='<editor symlink with parameter>'
in both ~/.bashrc & ~/.bash_profile . The symlink is subl, and the parameter is -w.
from the prompt it is:
subl -w
I have restarted terminal after each but every time I enter:
edit test-file.md
it opens TextWrangler (not the editor I've set). I've tried opening the symlink from the command line with no problem. I realize that I should probably just get used to typing the symlink, but the anal side of me wants to know why I can't set the default editor.
Any help with this trivial problem would be appreciated, thanks in advance!
I'm not even sure what edit command is. i don't have in on my Mac OS X Lion. Whatever it is, sounds like it ignores the EDITOR env variable and uses your MacOS X application settings.
What you want can be accomplished with the alias shell command though:
alias edit=/path/to/vim