Can not open vscode which install via anaconda in terminal on macOS - visual-studio-code

run code in terminal
zsh: command not found: code
But, it is normal in launchpad. May be a problem with environment variables, I don't know how to solve it.

Press Command+Shift+P, type “install code” and select the highlighted option.

Related

VS_Code : Shell Integration Failed To Activate

When i hover on my vscode terminal name: (in terminal's upper right corner named "Powershell")
it shows : shell intergartion failed to activate,
how to solve this error, while
I tried installing vs code again but still no change, and also installed powershell 7
There are a few potential solutions for this issue.
Make sure that you have the latest version of VS Code and the Shell Integrate extension installed.
Check that the integrated terminal in VS Code is set to the shell you want to use (e.g. PowerShell, Command Prompt, Bash).
Try running VS Code as an administrator.
If you are using Windows, try adding the path of the shell you want to use (e.g. C:\Windows\System32\bash.exe) to the "terminal.integrated.shell.windows" setting in your VS Code settings.
You can also try reinstalling vscode and the extension.
If none of the above solutions work, you can try searching for specific error messages in the output panel of vscode or in the output of the terminal.

I have to "source ~/.zshrc" everytime I open a new terminal only in vscode

Currently have to manually write source ./zshrc to get my zsh plugins to work within the vscode terminal window, however I dont have this issue if I open a zsh shell outside of vscode. I am using Debian on wsl2.
In terminal I get proper syntax example (due to a plugin)
However in vscode I dont unless i run source ./zshrc
As seen here:

Mac OS latex workshop does not build pdf, error shown is: Recipe terminated with fatal error: spawn pdflatex ENOENT

I installed latex workshop in VSCODE (on Mac OS), but the pdf does not build. Instead it throws the error:
Recipe terminated with fatal error: spawn pdflatex ENOENT.
Does anyone know the solution as I would have assumed the package would work by simply installing?
I found this issue to occur when launching VSCODE from the anaconda GUI. Launching VSCODE directly in launchpad on MAC OS did not through any errors and simply compiled and built the pdf. Hence, this issue appears to be specific to the anaconda installation and launch.
You need to install MacTex for Latex Workshop to work. After installing MacTex, you'll see TexLive Utility which you will use to install all the packages.
If you have all of it installed, then it throws an error because the environment variable is not set in PATH. You can check this by typing
echo $PATH in your terminal or reading the error message in the log.
To fix this:
Open your Library folder and navigate over to TexShop. Open "Engines" and move latexmk engine from "inactive" back to "Engines" folder.
After doing this, you have to add /usr/local/texlive/2022/bin/universal-darwin to your $PATH.
Open Terminal and type ls -a to view all files.
Type open .zshrc in the terminal and add /usr/local/texlive/2022/bin/universal-darwin: after bin:. Save the text editor and close it.
Now, type source .zshrc in the terminal.
Restart your Visual Studio Code, and it should work. Type echo $PATH in Terminal and you should be able to see the path we just added.

How to open "vscode" and "zsh in vscode" using terminal?(already install shell code command in path in VsCode)

I just want to open vscode in terminal and I already install shell code command in path in vscode, I restart terminal by quitting and open and I have my vscode download in Mac not in application cause when I move vscode to application it won't open and I have to move vscode to trash and redownload it again, do I have to also restart my computer?
vscode
Shift + Command + P
shell command install 'code' command in path
Start with pwd in terminal
pwd
For open zsh in vscode:
code ~/.zshrc
zsh: command not found: code
For open vscode:
code
zsh: command not found: code
For check out vscode version in terminal:
code -v
zsh: command not found: code
Youtube search: vscode in macbook
Found this:
How to Install Visual Studio Code on Mac
https://www.youtube.com/watch?v=tCfbi5PF1y0
Btw this is the long way, the short way is to:
Open the Command Palette (Cmd+Shift+P) and type 'shell command' to find the Shell Command: Install 'code' command in PATH command.
Website:
https://code.visualstudio.com/docs/setup/mac
the reason for vscode not open cause of the data confuse which cause the vscode to not open, to solve the vscode not open when you put vscode in application, you basically have to redo the uninstall & install again, below are todo list if you are having the same problem:
step 1 uninstall and install vscode
step 2 move vscode from download to application
step 3 open vscode in launchpad
Step 4 uninstall & Shell Command: Install 'code' command in PATH command.
step 5 quit terminal and open it again
step 6 use the command line in above question to check if it work
Start with pwd in terminal:
pwd
code
code -v
code ~/.zshrc

Can't run CS50 command in VisualStudio code Terminal

Commands of CS50 are no more working anymore. I tried to redo steps of configuring SSH following the link https://cs50.readthedocs.io/github/#ssh , but I'm facing the message error present in the image below : CS50 command image error
After checking the documentation you provided and assuming it's what you followed,
https://cs50.readthedocs.io/projects/check50/en/latest/ states "Under Windows, please install the Linux subsystem. Then install check50 within the subsystem."
But in your picture you are using PowerShell (PS) so you can either start wsl from it by using the command wsl or you can open a new terminal from the vscode gui but make sure you selected wsl this time !