How to add an application to Mac Applications folder

1

1

I'm looking to add software installed elsewhere (eg. home or opt) to the Mac's (10.8) Applications folder.

The goal here is to get all the benefits like the application listing in the launcher and the ability to add the program as a default for the open command.

I've tried symbolic links, but had some issues and I'm guessing that isn't the best practice.

What's the best way to do this?

Adam

Posted 2013-08-07T17:00:51.110

Reputation: 145

Out of curiosity, why would you install programs in home? Opt makes some sense for CLI programs, but perhaps I am not sure of other valid reasons for that one. Anyway, what do you mean "had some issues" - what issues did you experience? – nerdwaller – 2013-08-07T17:04:42.623

One example is the default for Spring Source STS is ~/springsource. Where would you suggest? When I did a symbolic link to my .app file the link couldn't be used for "Open with..." when I looked it up in the open dialog. – Adam – 2013-08-07T18:12:28.647

Please be as specific in your question as possible about what "applications" you need there. – slhck – 2013-08-07T18:49:10.787

@nerdwaller It makes sense on multi-user systems to only install software for specific users. In fact, /Users/username/Applications is a standard location for user-specific applications. The counterpart on Linux is probably /home/username/bin where you'd install tools for your own account only (not everyone is a sudoer), or patched system tools.

– Daniel Beck – 2013-08-08T06:29:16.590

@DanielBeck - I must take things too literally, because I read "home" (i.e. ~/). I understand the reasoning for ~/Applications, but those also show up by default for the user (at least if I understand the OP correctly, their's isn't installed there and is not showing up and they are trying to symlink to one of the Applications folders). – nerdwaller – 2013-08-08T12:41:22.827

My specific case I am working on right now is to use Spring's STS. – Adam – 2013-08-09T19:41:20.493

Answers

4

Setting the default application for a file type to an application like /usr/local/Cellar/macvim/7.3-66/MacVim.app should already work.

If you use Alfred, you can add directories like /usr/local/Cellar to the search scope. If you use Spotlight, you can create aliases instead of symlinks for the applications. Spotlight treats symlinks to system files as system files but not aliases to system files.

You can create aliases in a shell by using osascript:

find /usr/local/Cellar -name \*.app|while read l;do osascript -e 'on run {a}' -e 'tell app "Finder" to make new alias file at POSIX file "/Applications" to POSIX file a' -e end "$l";done

Lri

Posted 2013-08-07T17:00:51.110

Reputation: 34 501

Thanks Lauri. I'm not following you with using Alfred or Spotlight. I have the option when right clicking a file to Get Info or Show Inspector and I'd also like the program to be available in Launchpad. – Adam – 2013-08-09T19:43:57.590

I thought you meant Spotlight by a launcher. But creating an alias to /Applications/ also seems to add an application to Launchpad. – Lri – 2013-08-10T06:33:44.513

Thanks Lauri, I think this answer is good. I think I was getting hung up on trying to point the default application at the alias, when it should point at the actual app. – Adam – 2013-08-12T18:00:15.597