I’m using Obsidian 1.12.7 installed as a system flatpak with Insider-Builds enabled in setttings.
Installing the CLI from the global settings puts a binary into $HOME/.local/bin/obsidian that subsequently fails with the error message of
`The CLI is unable to find Obsidian. Please make sure Obsidian is running and try again.`
The method described in the docs (`ln -s /var/lib/flatpak/exports/bin/md.obsidian.Obsidian ~/.local/bin/obsidian`) works for me, so I’m assuming this is a system/ecosystem detection going wrong. Happy to provide other debug info if I can.
So it looks like the flatpak sandboxes the socket, meaning the cli tool can’t find it. The below is my current work around which has to be run each time before obsidian starts up. Maybe the devs can see this and implement a more durable solution for their flatpak builds.
Thank you! That was really helpfull. However, i use zsh so the single quotes broke the command. For other folks using obsidian and zsh, that’s the workaround that worked for me:
Edit your ~/.zshrc and add the following:
unalias obsidian 2>/dev/null # clear any existing alias that may break
obsidian() {
ln -sf /run/user/$(id -u)/.flatpak/md.obsidian.Obsidian/xdg-run/.obsidian-cli.sock
/run/user/$(id -u)/.obsidian-cli.sock 2>/dev/null
command obsidian “$@”