homebrew-cask icon indicating copy to clipboard operation
homebrew-cask copied to clipboard

Apps that need to be in `/Applications` to work

Open vitorgalvao opened this issue 9 years ago ‱ 18 comments

Not apps that ask to be moved, but the ones that are broken if not there (even if a symlink works, it should still be included). Maintainers should feel free to edit and add to the list.

vitorgalvao avatar Jul 26 '15 18:07 vitorgalvao

Removed caveats from casks in this list (when there was one). So I think this issue can also be closed 🎉

tsparber avatar May 31 '16 21:05 tsparber

This can’t be closed, as users can still pick a custom directory for installing. In #13201, these are the cases that will need a :required_location (see the New stanzas/keys/flags to enhance these changes section). image

vitorgalvao avatar May 31 '16 21:05 vitorgalvao

Sorry, forgot about that. 😐 gnubg can be added to the list.

tsparber avatar May 31 '16 21:05 tsparber

Not to worry. Added gnubg to the list, thank you.

vitorgalvao avatar May 31 '16 21:05 vitorgalvao

Hi, while google-chrome itself works, some extensions such as 1Password break when chrome is not in the Applications folder.

allanchau avatar Sep 09 '18 23:09 allanchau

@allanchau That’s a good point, but the list is focused on the application itself breaking.

vitorgalvao avatar Sep 09 '18 23:09 vitorgalvao

Edited the list to remove casks we no longer have.

vitorgalvao avatar Mar 23 '20 15:03 vitorgalvao

Hi, is this an issue I can work on? I'm very new to open source contribution, but I would love to help.

AnansiOmega avatar Feb 24 '21 18:02 AnansiOmega

Hi, is this an issue I can work on?

Hi! Sure! No one’s working on it and it’s low priority, so please go ahead. Though looking at it now, it might benefit from a simpler approach:

Add :required_location. Example: app 'FontForge.app', required_location: '/Applications'. It means the artifact needs to be in a certain location to function correctly and as such the installation will fail if the target directory is a different location.

Pseudo-code for :required_location, considering an app:

if (cask has :required_location) and (REQUIRED_LOCATION != APPDIR_DESTINATION) and (not using --force)
    print_warning "This app needs to be in REQUIRED_LOCATION to work properly. Use `--force` to install to APPDIR_DESTINATION or `--appdir APPDIR_DESTINATION` to install to the proper location."
end

That’s way simpler and doesn’t surprise the user by installing somewhere unexpected by default. Note that APPDIR_DESTINATION is either the default when it’s unset (/Applications) or whatever the user decided with --appdir. Realistically, I don’t think :required_destination will ever be anything other than /Applications, but it doesn’t hurt to have the flexibility.

Bonus points if the feature is versatile enough to be repurposed to binary at a later time if needed (though don’t worry about it yet if you don’t want to or it makes it too complex).

Thank you for offering!

vitorgalvao avatar Feb 24 '21 19:02 vitorgalvao

Hey @vitorgalvao is there any way to run tests on where the application downloads? I've been trying to get a lay of the land. I noticed some documentation that recommends:

$ brew /Users/anansi/Development/code/openSource/homebrew-cask/Casks/fontforge.rb google-chrome

but that gives me an error: " undefined method `cask' for main:Object " ( also, I've run brew upgrade and brew update to see if that would fix it, but to no avail )

Also, for clarity. All of the items listed on the original post are the ones that need the change? ( asking because I can't find, cdock, cmpl, and gnubg. I assume they no longer exist, because this post is incredibly old. )

AnansiOmega avatar Feb 26 '21 16:02 AnansiOmega

is there any way to run tests on where the application downloads?

I don’t understand the question. Are you looking for brew fetch?

I noticed some documentation that recommends

That command doesn’t make sense, because after brew there should always be a verb, not a cask name or path. If you found that in official documentation, please let me know where so I can fix it.

All of the items listed on the original post are the ones that need the change?

The ones we know about, yes.

asking because I can't find, cdock, cmpl, and gnubg. I assume they no longer exist, because this post is incredibly old.

You are correct. That’s also why I said this is low priority. But it should also be simple enough to get a feel for the codebase if you plan on contributing larger changes later on. If you’d prefer something more challenging or that would make a larger impact, I can point you to something as well!

vitorgalvao avatar Feb 26 '21 18:02 vitorgalvao

I don’t understand the question. Are you looking for brew fetch?

I think so, I'll play around with it more. ( I'm still incredibly lost on how everything works, but I'll figure it out. )

That command doesn’t make sense, because after brew there should always be a verb, not a cask name or path. If you found that in official documentation, please let me know where so I can fix it.

I might be in the wrong here, but the link is: https://github.com/Homebrew/homebrew-cask/blob/master/doc/development/hacking.md

If you’d prefer something more challenging or that would make a larger impact, I can point you to something as well!

I'd love to, but I'd like to get a handle of working within homebrew first, and being able to tackle problems without having anyone hold my hand throughout the process.

AnansiOmega avatar Feb 26 '21 18:02 AnansiOmega

@vitorgalvao Hey, I can't figure out how to create a new stanza.

AnansiOmega avatar Feb 26 '21 20:02 AnansiOmega

I might be in the wrong here, but the link is: https://github.com/Homebrew/homebrew-cask/blob/master/doc/development/hacking.md

Thank you. Notice that in that case it’s calling a subcommand through its path, and you were invoking a cask. Different thing. But ignore that file because it’s outdated. Any documentation you look at for changing the core should be in https://github.com/Homebrew/brew.

I can't figure out how to create a new stanza.

You don’t want to create a new stanza, but rather a new parameter of an existing stanza. You want required_location to be added to the app stanza, which already supports the target parameter, so that might help.

vitorgalvao avatar Feb 26 '21 23:02 vitorgalvao

I apologize for asking so many questions, but I have more. If there's any resource I can go to ask simple questions like these please let me know so that I don't take up all of your time.

When it comes to adding required_location as a parameter to a stanza I think I found the file where the changes would need to be made, but I'd like to be certain. In Homebrew the path to the file is Library/Homebrew/cask/artifact/relocated.rb ? In other words the file that I need to add in the method of required_location should be in the relocated.rb ?

If that's the case, I have a follow up question because I know this will be a problem I'll stumble upon. How would I be able to invoke the method of 'required_location' to make sure that it's doing the right thing. I'm accustomed to using byebug, and then invoking the file. Thank you.

AnansiOmega avatar Feb 27 '21 21:02 AnansiOmega

I apologize for asking so many questions, but I have more. If there's any resource I can go to ask simple questions like these please let me know so that I don't take up all of your time.

When it comes to adding required_location as a parameter to a stanza I think I found the file where the changes would need to be made, but I'd like to be certain. In Homebrew the path to the file is Library/Homebrew/cask/artifact/relocated.rb ? In other words the file that I need to add in the method of required_location should be in the relocated.rb ?

If that's the case, I have a follow up question because I know this will be a problem I'll stumble upon. How would I be able to invoke the method of 'required_location' to make sure that it's doing the right thing. I'm accustomed to using byebug, and then invoking the file. Thank you.

@vitorgalvao If you have a chance.

AnansiOmega avatar Mar 03 '21 17:03 AnansiOmega

If there's any resource I can go to ask simple questions like these

https://github.com/Homebrew/discussions might work.

vitorgalvao avatar Mar 04 '21 12:03 vitorgalvao

I just opened this which is similar: https://github.com/Homebrew/brew/issues/14517.

thoran avatar Feb 06 '23 07:02 thoran