Skip to content

Conversation

@ilovezfs
Copy link
Contributor

No description provided.

@BrewTestBot BrewTestBot added the in progress Maintainers are working on this label Sep 30, 2016
@ilovezfs
Copy link
Contributor Author

based on that test run, it sure looks like it will need to be bootstrapped with the existing ones rebuilt against the versioned name

@MikeMcQuaid
Copy link
Member

CC @Homebrew/maintainers for thoughts on this change and @penman too.

@zmwangx
Copy link
Contributor

zmwangx commented Sep 30, 2016

Could someone write up the rationale behind this change? I see discussions in team chat but not everyone read transcripts after the fact, and @alyssais (looks like the handle changed) doesn't have access to that.

@ilovezfs
Copy link
Contributor Author

The existing bottles are linked against opt/boost not opt/[email protected]. So renaming boost to [email protected] breaks them. The alternatives are not to rename boost to [email protected] and just to go from boost to [email protected] (that pattern is already underway with openssl), or have duplicate boost and [email protected] formulae alongside [email protected], until dependents are transferred from boost to [email protected] or [email protected], and then delete the duplicate boost formula, and create a boost alias instead.

@zmwangx
Copy link
Contributor

zmwangx commented Sep 30, 2016

Do we want to limit opt linking for aliases to @ formulae only? Having both cowthink and cowsay in opt is pointless (but harmless either).

@alyssais
Copy link
Contributor

I like the idea that there's nothing special about @ formulae (that they're just normal aliases), but that could definitely end up not being practical.

@ilovezfs
Copy link
Contributor Author

@alyssais I agree with you. I think we'll want a full-on DSL for this stuff at some point relatively soon hehe

@alyssais
Copy link
Contributor

I think this looks good. Is it cool if I make a couple of comments on the code?

@ilovezfs
Copy link
Contributor Author

ilovezfs commented Sep 30, 2016

of course!

based on that brew tests run, I'm 👎 on my own PR though :)

@alyssais
Copy link
Contributor

based on that brew tests run, I'm 👎 on my own PR though :)

Ah, sure. I'll wait a bit until that's resolved then. :)

@MikeMcQuaid
Copy link
Member

I like the idea that there's nothing special about @ formulae (that they're just normal aliases), but that could definitely end up not being practical.

I agree with this.

@DomT4
Copy link
Contributor

DomT4 commented Sep 30, 2016

The alternatives are not to rename boost to [email protected] and just to go from boost to [email protected] (that pattern is already underway with openssl)

This would be my recommendation, FWIW.

@DomT4
Copy link
Contributor

DomT4 commented Sep 30, 2016

Although we need to resolve the issues around keg_only and so on either way with Boost, especially if my comments on boost and boost-python last night prove accurately remembered. It didn't matter for openssl and [email protected] because both are always going to be keg_only when Homebrew is located in /usr/local.

@MikeMcQuaid
Copy link
Member

The alternatives are not to rename boost to [email protected] and just to go from boost to [email protected] (that pattern is already underway with openssl)

This would be my recommendation, FWIW.

Even if that's the case I think this alias change would be a good one.

@DomT4
Copy link
Contributor

DomT4 commented Sep 30, 2016

Yes, I have no issues with aliases also being in opt pointing to the "true" source of the alias, even for non-@ formulae. Might be a good idea to add some tests, if possible, for this change though to ensure we don't bork it in future somehow.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can do the each even if empty? as it'll be a no-op.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can get this from Formula#aliases (which also handles the no-tap case)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, aliases.each is a no-op if this is empty so you can just use .each without the check.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will a symlink? not always exist??

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Broken symlinks return false for exist?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TIL.

@ilovezfs ilovezfs closed this Oct 1, 2016
@BrewTestBot BrewTestBot removed the in progress Maintainers are working on this label Oct 1, 2016
@MikeMcQuaid MikeMcQuaid reopened this Oct 1, 2016
@MikeMcQuaid MikeMcQuaid added the in progress Maintainers are working on this label Oct 1, 2016
@ilovezfs
Copy link
Contributor Author

ilovezfs commented Oct 3, 2016

@MikeMcQuaid I'm not sure it matters but do you prefer opt/boost -> [email protected] or opt/boost -> ../Cellar/[email protected]?

@MikeMcQuaid
Copy link
Member

@ilovezfs Then latter just in case people are relying on being able to follow one layer of symlinks to find the Cellar 👍

@MikeMcQuaid
Copy link
Member

There's some test failures but code and local testing look good to me.

@MikeMcQuaid
Copy link
Member

@ilovezfs Thoughts on this? Shout if you want help with test failures.

ilovezfs and others added 2 commits February 20, 2017 14:14
in case people expect to be able to find the prefix by only resolving
the symlink once (e.g., if they're using readlink not realpath)
@MikeMcQuaid MikeMcQuaid merged commit 60ba0e4 into Homebrew:master Feb 20, 2017
@ilovezfs
Copy link
Contributor Author

@MikeMcQuaid this has introduced a bug for anything that has an alias but was installed before this PR shipped:

iMac-TMP:~ joe$ brew uninstall ag
Uninstalling /usr/local/Cellar/the_silver_searcher/1.0.2... (10 files, 113.1K)
Error: No such file or directory - /usr/local/opt/ag

@MikeMcQuaid
Copy link
Member

@ilovezfs Working on it.

@MikeMcQuaid
Copy link
Member

@ilovezfs Opened #2085 to address this.

@Homebrew Homebrew locked and limited conversation to collaborators May 3, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

in progress Maintainers are working on this

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants