- Install any third-party plugin that executes system commands from Obsidian (e.g., Templater or Obsidian Git)
- Try to execute code that uses a package that was installed via Homebrew (e.g., writing a user function in Templater or using
git-lfswith Obsidian Git)
- Obsidian will not be able to find the package, and will throw an error.
I expect to successfully run the system commands using the packages I downloaded with Homebrew.
With both Templater and Obsidian, I get the error
command not found or
PACKAGE not found where PACKAGE is whatever I was trying to use (
tldr, anything I installed with Homebrew).
This error occurred on both the main Obsidian version and the Insider version.
- Operating system: MacOS Monterrey
- Debug info:
Obsidian version: v0.13.21
Installer version: v0.12.15
Operating system: Darwin Kernel Version 21.2.0: Sun Nov 28 20:28:54 PST 2021; root:xnu-8019.61.5~1/RELEASE_X86_64 21.2.0
Login status: logged in
Catalyst license: supporter
Insider build toggle: on
Live preview: on
Legacy editor: off
Base theme: dark
Community theme: Minimal
Snippets enabled: 5
Safe mode: off
Plugins installed: 18
Plugins enabled: 17
2: Find unlinked files and unresolved links
3: Tag Wrangler
6: Periodic Notes
8: Style Settings
9: Tag Page Preview
10: Sliding Panes (Andy’s Mode)
12: Contextual Typography
13: Metadata Extractor
14: Advanced URI
15: Obsidian Git
16: Advanced Tables
My guess is that it’s the same underlying problem that Obsidian does not include
/usr/local/bin on the path when it executes code, and, when Homebrew installs packages, it places the symlinks to those packages in
There was also an old forum post describing this problem that is now locked and wasn’t resolved.
For Obsidian Git, I followed the steps discussed in that issue and added
PATH=$PATH:/usr/local/bin to the top of all of the hooks added by
git-lfs. I also updated my global
.gitconfig to refer to
/usr/local/bin/git-lfs instead of just
git-lfs. With those changes, I was able to use Git LFS with Obsidian Git.
For Templater, I defined my functions as bash scripts, and I included
PATH=$PATH:/usr/local/bin at the top of each script. From there, I was able to write a user-defined function in Templater to run my bash script successfully.