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

Preserve installed_on_request for dependencies #3653

Merged
merged 1 commit into from
Jan 9, 2018

Conversation

alyssais
Copy link
Contributor

@alyssais alyssais commented Jan 9, 2018

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same change?
  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes? Here's an example.
  • Have you successfully run brew tests with your changes locally?

Fixes #3642.

It would be nice if the Tab returned from for_formula when the formula isn't installed didn't look like a real one that had been installed on request…

Test cases

dd5f216 is the commit before libdvdcss was updated.

export HOMEBREW_BUILD_FROM_SOURCE=1
brew install libdvdread
jq .installed_on_request "$(brew --prefix libdvdcss)/INSTALL_RECEIPT.json"
# should be false
export HOMEBREW_BUILD_FROM_SOURCE=1
export HOMEBREW_NO_AUTO_UPDATE=1
git -C "$(brew --repo homebrew/core)" checkout dd5f216bfe7d8d186853f303fb68cb4c0ecbdba8
brew install libdvdcss
git -C "$(brew --repo homebrew/core)" checkout master
brew install libdvdread
jq .installed_on_request "$(brew --prefix libdvdcss)/INSTALL_RECEIPT.json"
# should be true (this is what is currently broken)
export HOMEBREW_BUILD_FROM_SOURCE=1
export HOMEBREW_NO_AUTO_UPDATE=1
git -C "$(brew --repo homebrew/core)" checkout dd5f216bfe7d8d186853f303fb68cb4c0ecbdba8
brew install libdvdread
brew uninstall libdvdread
git -C "$(brew --repo homebrew/core)" checkout master
brew install libdvdread
jq .installed_on_request "$(brew --prefix libdvdcss)/INSTALL_RECEIPT.json"
# should be true

@MikeMcQuaid
Copy link
Member

Looks good, thanks @alyssais! Can you split whitespace-refactoring-only changes into additional commits in future? Makes it easier to review.

@alyssais alyssais merged commit f06b54f into Homebrew:master Jan 9, 2018
@alyssais alyssais deleted the installed_on_request branch January 9, 2018 20:02
@Homebrew Homebrew locked and limited conversation to collaborators May 4, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Formula installed as a dependency will always be marked as *not* installed_on_request
2 participants