Zprofile not found in Mac OS Terminal - bash

I have a new mac that I have been setting up with homebrew, git, node, vs code etc. I noticed that some applications were somehow being installed on bash terminal instead of zsh terminal. Even though I was able to fix that, I now have an error message of
/Users/*****/.zprofile:1: = not found
I tried to create a z profile using
touch ~/.zprofile
How can I fix this error message?

Related

Nix on Vscode terminal

I'am having issue using nix on my Vscode terminal, if I type nix-shell on my terminal everything work just fine but if I try on Vscode terminal it says:
zsh: command not found: nix-shell
I already had this issue before and fix it with adding my PATH in the settings.json file at terminal.integrated.env.osx.
The paths that I add are "terminal.integrated.env.osx": { "PATH" : "/Users/my_name/.nix-profile/bin:/opt/homebrew/bin:/Users/my_name/opt/miniconda3/bin:/Users/my_name/opt/miniconda3/condabin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin", "NIX_PATH" : "/Users/my_name/.nix-defexpr/channels"},
I also don't know why my PATH is so long and if I did something wrong.
Nevertheless adding those line on my settings.json fie fixed the issue for a while but it doesn't work anymore and I don't know why.
I am on a MacBook Air (M1, 2020), macos bigsur 11.2.3
I am using the default Terminal.app application provided by mac.
I tried to put integrated and external on terminal settings in Vscode, neither of them work
Thanks for reading and sorry if my explanation aren't good.

After updating my Mac OS to Catalina, Flutter is not working anymore in Android Studio. I deleted and re-installed, but still not working

Please Please help. After updating the OS to Catalina, Android Studio would still open, but none of my Flutter apps will work and the emulators do not open (they say 'Loading')
I unistalled Flutter and re-installed it, but in the Terminal when I type in flutter doctor -v, it says "zsh: command not found: flutter"
Is this because I'm no longer using bin (or bash), and now using zsh?
Can someone tell me what I can do to solve this issue? Im not very good at entering Terminal commands, so what exactly would I type to fix this issue? (I'm a beginner)
When I was entering vim bash_profile in the Terminal, I entered the following as the Export Path:
export PATH="$PATH:/Users/raymondfontaine/Developer/flutter/bin"
I had the same problem and it occurred after switching from bash to zsh. A far as I know, you have three different options.
Switch your Terminal back from zsh to bash by typing chsh -s /bin/bash and restart your Terminal. Note: You can always switch back to zsh by typing chsh -s /bin/zsh and restarting your Terminal.
You can tell zsh to use the paths specified in your bash_profile file by typing source ~/.bash_profile into your Terminal. Note: You have to do this every time you open a new Terminal.
The two options above are probably not "Best Practice". The best solution would be to set environment variables for zsh as suggested by the flutter Tutorial: Update your Path.
In your case you have to type nano $HOME/.zshrc into your Terminal enter export PATH="$PATH:/Users/raymondfontaine/Developer/flutter/bin" there, save the file and restart the Terminal. After that flutter doctor -v should run as usual.
Also the emulators in Android Studio should load again. But if you still cannot start them via the Dropdown, try opening them via Tools > AVD Manager. This worked for me while they were not visible in the Dropdown Menu.

vim Mac OS X install with gui-support

I have Mac Pro, with OS X 10.9.4 (can't upgrade to Yosemite yet), and I'm trying to build vim7.4 with gui-support, or get any kind of gui-support. My current vim is version 7.3, I'm guessing, that's the default vim that ships with macs. I have the Terminal.app and iTerm2.app, my vim rc has the default
set term=xterm-256colors
or what have you.
What I have so far:
macvim
The colors look great, basically it's the same setup I had on my ubuntu system, but it's really annoying that it opens a new window. Is there a way to get it to open within my terminal? (not launch it from the terminal, open inside of it)
As I've said I have the regular vim7.3
And while I can use color-schemes, they look like garbage compared to my ubuntu system. I suppose this must be due to gui-support option? I tried, CSApprox but that gives me a weird error.
So I decided to simply build vim 7.4 and enable gui support, but I get random errors.
My basic config make looks like:
./configure --enable-gui=yes
make
At which point it complains about missing header file etc. , I figured this should not be that hard.
Any tips?
The basics of what I'm trying to do is:
Have a vim version installed with gui-support, or a work-around where my colors are all screwed up.
Thanks!
Building Vim on Mac OS X is a waste of time.
Step 1: Download the appropriate MacVim build from here.
Step 2: Put MacVim.app into the /Applications/ directory.
Step 3: Put the bundled mvim script somewhere in your PATH.
Done.
To run MacVim in your shell:
$ mvim -v filename
To run MacVim from your shell:
$ mvim filename
Building Vim with GUI on macOS using Homebrew:
brew edit vim.
Add a new line with option for GUI:
option "enable-gui", "Enable GUI mode"
Change from no to yes in the following line:
opts << "--enable-gui=no"
Install or re-install vim:
brew reinstall vim --enable-gui
Troubleshooting:
If you've errors related to Python 3, see: vim's GH-2754.
Checkout new Homebrew PR at GH-25785 with above patch.

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.

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

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.

Resources