Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

need to update binary path in .plist after upgrade #194

Open
gperciva opened this issue Jul 18, 2018 · 3 comments
Open

need to update binary path in .plist after upgrade #194

gperciva opened this issue Jul 18, 2018 · 3 comments

Comments

@gperciva
Copy link
Member

Looks like the .plist hard-codes the version-specific path, i.e.

/usr/local/Cellar/tarsnap-gui/1.0/Tarsnap.app/Contents/MacOS/Tarsnap

We'll need to update this when there's a new version, or (probably better) make sure that we get the symlink to that file rather than the path itself. (I assume that brew sets up something like /usr/local/bin/tarsnap -> /usr/local/Cellar/tarsnap-gui/1.0/Tarsnap.app/Contents/MacOS/Tarsnap )

Thread here:
http://mail.tarsnap.com/tarsnap-users/msg01457.html
http://mail.tarsnap.com/tarsnap-users/msg01464.html

@gperciva
Copy link
Member Author

This is being addressed in #196 (that PR still needs to add launchd unload ... && launchd load ...).

@DomT4
Copy link

DomT4 commented Aug 21, 2018

or (probably better) make sure that we get the symlink to that file rather than the path itself.

If you use the opt prefix it won't break across upgrades, and indeed, will keep working if people unlink tarsnap-gui from HOMEBREW_PREFIX for whatever reason. Opt prefix is HOMEBREW_PREFIX/opt/tarsnap-gui, with HOMEBREW_PREFIX usually being /usr/local.

FWIW, as long as the formula is installed, brew --prefix <xyz> will always return the unversioned symlink rather than the versioned path.

@shawwn
Copy link
Contributor

shawwn commented Aug 22, 2018

The cask formula mentioned here uses the binary stanza of the cask formula to ensure tarsnap-gui is in the user's PATH.

The takeaway is that the plist file can just hardcode /usr/local/bin/tarsnap-gui.

@gperciva gperciva mentioned this issue Oct 20, 2023
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants