Can't launch anything from terminal after uninstalling fink! Mac Lion - terminal

I've got a big problem, I can't launch anything from the terminal, not python, not emacs (or aquamacs), not even 'which'.
I was using homebrew to try to install ffmpeg and was having difficulties so I decided to pay attention to the warning that always come up advising me to uninstall fink. I removed the sw directory from my root directory, which is what the fink website told me to do and was confirmed on many blogs and message boards after a quick google search.
And since then nothing has worked, I'm almost certain that this was the cause of the problem because after removing sw I immediately tried home brew again and it said 'brew: command not found'. I get the same warning with any and every program I try to launch.
I use Mac OS Lion on a 6 year old MacBook.
Any ideas?

You probably busted your PATH. You can use absolute paths to commands until you get it fixed. For example:
/bin/mv ~/.profile ~/.profile.bak
/bin/mv ~/.bash_profile ~/.bash_profile.bak
Then open a new Terminal window, where standard things should now work. and repair your profile script.

Related

MacVim on OSX / Yosemite: no editor windows visible at all

Installed MacVim on my Yosemite 10.10.2 Macbook Pro today from http://www.macupdate.com/app/mac/25988/macvim
The problem is that no editor window(s) are visible. If I open a file using the menu, there's simply no effect: no editor window appears. It's not hidden behind other windows, it's not listed in the Windows menu, it's just entirely undisplayed.
Strangely, the file will appear in the MRU list, though. So this renders the entire editor completely useless. Should I just build gvim myself? Is this app actually being maintained by anyone?
I'd read some answers which suggest running:
brew install macvim
... does the trick.
You might want to try that first.
What worked for me...
However, this didn't work for me because although it updated my macvim, the one being linked to in the /Applications folder was not the version being updated by brew.
So, here are the steps I had to take.
Quit MacVim if open.
Delete the MacVim file in /Applications.
In the terminal, run:
brew install macvim --override-system-vim
Run (this will add the link to your Applications file):
brew linkapps macvim
I can't be sure every step above is required, or that the --override-system-vim flag is required, but I can tell you that doing the above steps worked for me.
Hope this helps.
It looks like MacVim development has been moved to a new repository (and maybe a different group of developers?):
https://github.com/macvim-dev/macvim
This repo has had changes applied to fix MacVim's graphical problems under Yosemite. (This is the same location that brew's macvim formula currently pulls its source from, which is why MacVim works on Yosemite when installed via brew.)
They also have a set of precompiled binary releases:
https://github.com/macvim-dev/macvim/releases
The latest ("snapshot 76") has worked fine for me in Yosemite so far. You just need to download the .tbz archive, double-click it to unpack to a folder, then drag the MacVim.app icon to Applications -- much easier and less invasive than installing a whole package management system and build environment! :)
Note: I had to execute a command given in another StackOverflow answer to correct a rendering glitch seen in full screen mode for snapshot 76:
$ defaults write org.vim.MacVim MMNativeFullScreen 0
I got the same problem today.
The solution:
mv ~/.vimrc ~/.vimrc_bak
It looks like there is something wrong with my .vimrc file.
I was having the same issue, and one of the answers in here helped me, but not for the reason explained so I thought this might be useful for others.
Some plugins might depend on the version of vim, and may work in version 7 but not in version 8, when you install MacVim this could be version 8, and the terminal vim version might be 7, both will use the same .vim folder and .vimrc to load the plugins and configuration, when you open the vim from terminal it might still work because the plugins were depending on vim version 7, but when you try to execute MacVim it will try to load the plugins using version 8 and then it will crash, the reason some of the answers worked it's because they are replacing the system vim, therefore MacVim and vim will be in the same major version, if you have upgraded from the previous version the best you can do it's to clear up the plugins folder and then load MacVim or vim and check that everything is working, then start applying the plugins one by one checking that they are not breaking vim. At least with this method I found that one of the plugins was not working as expected and removing it solved the "MacVim" issue.
In summary:
- move your .vim as .vim_bak
- move your .vimrc as .vimrc_bak (suggested by #hai feng kao)
And test if this solves the issue, if that's the case then a plugin is breaking your installation and you will need to activate some and figure out which is the one that causes the issue.
Hope this helps to others, I've followed a lot of these recommendations without success until I decided to upgrade vim (terminal) and this started to break as well, that pointed me in the right direction.
Again hope this saves some hours for some.
I had the same symptom with MacVim launching with no window and command-N doesn't start any a new one. brew re-install didn't help.
It turned out there was another instance of macvim installed on my system somehow, in the Downloads folder. I found out by clicking "MacVim" --> "About MacVim" and it was a version from 2014. I found the instance and deleted it.
I created an alias for the newly installed version and copied that into Applications folder so spotlight search can find the new one. That solved my problem.
I had this problem upon updating from MacOS 10.12.5 to 10.12.6.
I uninstalled MacVim by moving it to the trashcan and downloading it again.
I would guess that the new version fixed whatever issue it had with the new operating system.

my terminal can't run on mac os 10.9?

I used to install something from github,I stoped it and I can't open iterm-2 too
and I open my Bash ,it appeared
Command not found: /usr/local/bin/bash
[Could not create a new process and open a pseudo-tty.]
I can't input any words.
What should I change?
Google is full of others asking for help with this problem and half-baked solutions, including reboots (re-login should do it if env changed), reinstall (why?) etc.
Looks like a clone of I messed up my terminal environment on Mac OS X and was wondering how to fix it judging by inability to start bash from /usr/local/bin. System default should be in /bin or /usr/bin.
Your terminal (console or iterm2) may have an option to specify shell explicitly, used that.

Issue with uninstalling Xcode 3.2 on Mountain Lion

I just upgraded to Mountain Lion (from Snow Leopard) so as to take advantage of Xcode 4.
Before installing Xcode 4, I would like to remove Xcode 3 (not required, but want to clean up before moving on).
The standard method of removing Xcode 3 is:
$ sudo <Xcode>/Library/uninstall-devtools --mode=all
However, when I issue this command, even from within the /Library folder, the only thing that happens is I get a "command not found" after entering my password.
I can see uninstall-devtools in Finder, so I know it's there. I just can't execute it for some reason. I've tried every possible way of running the uninstall tools.
Assistance is greatly appreciated. Thanks.
If the file really is there, type sudo in the terminal window (with a trailing space), drag and drop the uninstall-devtools file on the window, then append --mode=all. That should clear any chance you have to make a typo or any other mistake.
Similarly to information I found in another SO article, my laptop's old XCode 3.2 didn't even have the uninstall-tools utility.
So it worked fine for me to simply delete the XCode.app folder.

Mac OS X 10.8.1 - Files no longer being watched

Just updated to OS X 10.8.1. I'm not sure if this is the cause, but basically immediately after, programs are unable to check for file changes.
In my makefile, the following command does not work (it doesn't trigger on file changes)
watchr -e "watch('scripts/.*\.js') {system 'make scripts'}"
On Sublime Text, when I make a new file in a folder, that new file is not shown in the sidebar, but it is created correctly in the directly.
This command, however works (based on Node's watch command, I believe):
stylus -w -u nib styles/ie8.styl -o public/styles
Anyone know what's going on or how to debug?
Edit: This isn't working now after rebooting again. I hate this! :/
I also ran into this issue with Sublime Text 2 as well as Guard (it started using a polling fallback).
I believe I found a fix:
Download Onyx and run it with all of the options under the automation tab checked
After it's done shut down your machine and turn it back on
At this point I was suddenly able to see new directories created using mkdir in terminal from within the Sublime Text 2 file browser. Guard was also working without the polling fallback.
I hope this helps, it was really starting to get on my nerves.
This isn't going to be very informative but maybe it will help...
There is a thread in the Sublime Text forums discussing this issue and it doesn't seem to be secluded to OS X 10.8.1.
There also seems to be a thread about watchr not always working, and that issue seems to be platform independent as well.
I would bet that you've become the unwitting victim of the 'Mac OSX' env vars change ...
Please take a look at the following to determine if your env vars are set correctly on Mountain Lion as the environment.plist is now deprecated ...
Env Plist Deprecated
Mac OSX - Sublime

VIM Flashing Issue

I'm SSH'ing in from my mac OSX (10.6.8) to a school server running centOS5 and when I attempt to use VIM, it won't stop flashing inside the mac terminal. Any idea's on how to fix this? Keep in my mind I do not have the authority to modify any /etc files or /bin files on the server, although I believe I can locally on my user. Also I would love to see anyone's really cool .vimrc config file they want to share.
Try these out:
set visualbell t_vb= " turn off error beep/flash
set novisualbell " turn off visual bell
Though the link may go stale in the future, for the time being this is the source: http://phuzz.org/vimrc.html
I also know that you can set this via terminal options on the MAC, though this is not likely the issue if you are ssh-ing. Anyway, I hope it helps. Good luck! :)
I´ve just had the same issue.
I solved it by disabling the setting "Allow blinking text" in the terminal text settings as shown in this
screenshot.
Regarding .vimrc config there are tons of versions to be found on google, especially github is a good place to go.
to stop beeping & flashing in both the console & the GUI versions of Vim try:
set noerrorbells visualbell t_vb=
autocmd GUIEnter * set visualbell t_vb=
I was pretty frustrated with macvim installed via brew.
First, on installation, it had an issue with the python version.
I did upgrade brew and python. Then I started macvim but it was flashing really bad, to eliminate, I had to ***disable core text renderin***g under preferences -> advanced options.
Finally, it got stable but couldn't open files or tabs.
objc[80401]: Class FIFinderSyncExtensionHost is implemented in both
/System/Library/PrivateFrameworks/FinderKit.framework/FinderKit
(0x10d099200) and
/System/Library/PrivateFrameworks/FileProvider.framework/OverrideBundles/FinderSyncCollaborationFileProviderOverride.bundle/Contents/MacOS/FinderSyncCollaborationFileProviderOverride
(0x115309c00). One of the two will be used. Which one is undefined.
So I decided to get rid off it altogether.
brew uninstall --force macvim
Installed it manually from here.
Once installed, I used the following command to create an alias. Add the following line to your .bashrc or .zshrc (for iTerm users).
alias mvim=/Applications/MacVim.app/Contents/MacOS/MacVim -g
Now reload your terminal session and type mvim. Enjoy!!

Resources