twibiral / obsidian-execute-code

Obsidian Plugin to execute code in a note.
MIT License
1.14k stars 67 forks source link

command not found #231

Closed JCzz closed 1 year ago

JCzz commented 1 year ago

If I add a shell code to be executed:

echo $PATH

It do not print the same $PATH as if I run the same command in macos terminal.

Update: This seems to be working on Windows

Do you know why?

hannesdelbeke commented 1 year ago

you have a typo in echo.

JCzz commented 1 year ago

For now I found that I can add to settings "shell/Inject Shell code":

export PATH=$PATH:/opt/homebrew/bin

Just add anything missing from your $PATH

It would be nice if Obsidian picked up from terminal $PATH. In my case I am on a mac terminal zsh.

Still great plugin!

twibiral commented 1 year ago

Hi @JCzz PATH variables are not included at the moment, as discussed in #37

JCzz commented 1 year ago

Hi @twibiral

Ok, thanks for info! 👍