Skip to content
This repository was archived by the owner on Apr 14, 2021. It is now read-only.

when running from source, find submodule shas too#6737

Merged
3 commits merged intomasterfrom
indirect/bundler-submodule-shas
Oct 20, 2018
Merged

when running from source, find submodule shas too#6737
3 commits merged intomasterfrom
indirect/bundler-submodule-shas

Conversation

@indirect
Copy link
Copy Markdown

We recently merged #6664 to prevent Bundler from (wrongly) claiming the
git commit of any parent directory when it is run from source. However,
Bundler is also run from source as a submodule in RubyGems, and in that
case it does not have its own git directory.

This commit resolves the failure in version_spec.rb that only appears
when the Bundler tests are run from a submodule, by explicitly checking
for that submodule, and using git ls-tree to get the sha if so.

Arguably, this is a bugfix compared to the previous behavior, which
would blindly print the current sha from the RubyGems repo, while
claiming that it was the sha of Bundler.

We recently merged #6664 to prevent Bundler from (wrongly) claiming the
git commit of any parent directory when it is run from source. However,
Bundler is also run from source as a submodule in RubyGems, and in that
case it does not have its own git directory.

This commit resolves the failure in version_spec.rb that only appears
when the Bundler tests are run from a submodule, by explicitly checking
for that submodule, and using `git ls-tree` to get the sha if so.

Arguably, this is a bugfix compared to the previous behavior, which
would blindly print the current sha from the _RubyGems_ repo, while
claiming that it was the sha of Bundler.
@hsbt
Copy link
Copy Markdown
Member

hsbt commented Oct 20, 2018

What's status this and #6733?

When they are merged 1-16-stable branch, I changed its HEAD revision on rubygems/rubygems repository and will release RG 2.7.8. Thanks!

@indirect
Copy link
Copy Markdown
Author

@bundlerbot r+

ghost pushed a commit that referenced this pull request Oct 20, 2018
6737: when running from source, find submodule shas too r=indirect a=indirect

We recently merged #6664 to prevent Bundler from (wrongly) claiming the
git commit of any parent directory when it is run from source. However,
Bundler is also run from source as a submodule in RubyGems, and in that
case it does not have its own git directory.

This commit resolves the failure in version_spec.rb that only appears
when the Bundler tests are run from a submodule, by explicitly checking
for that submodule, and using `git ls-tree` to get the sha if so.

Arguably, this is a bugfix compared to the previous behavior, which
would blindly print the current sha from the _RubyGems_ repo, while
claiming that it was the sha of Bundler.

Co-authored-by: Andre Arko <andre@arko.net>
@indirect
Copy link
Copy Markdown
Author

@hsbt see #6752 for backport to 1-16-stable 👍🏻

@ghost
Copy link
Copy Markdown

ghost commented Oct 20, 2018

Build succeeded

ghost pushed a commit that referenced this pull request Oct 20, 2018
6752: backport #6737 to 1-16-stable r=indirect a=indirect



Co-authored-by: Andre Arko <andre@arko.net>
@ghost ghost merged commit 9849d56 into master Oct 20, 2018
ghost pushed a commit that referenced this pull request Oct 20, 2018
6752: backport #6737 to 1-16-stable r=hsbt a=indirect



Co-authored-by: Andre Arko <andre@arko.net>
@hsbt
Copy link
Copy Markdown
Member

hsbt commented Oct 20, 2018

@indirect Thanks a lot. I will prepare to release RG 2.7.8.

@hsbt hsbt deleted the indirect/bundler-submodule-shas branch October 20, 2018 22:50
hsbt pushed a commit that referenced this pull request Nov 21, 2018
backport #6737 to 1-16-stable

(cherry picked from commit 8a789f0)
hsbt pushed a commit that referenced this pull request Nov 21, 2018
backport #6737 to 1-16-stable

(cherry picked from commit 8a789f0)
@colby-swandale colby-swandale added this to the 2.0.2 milestone Feb 25, 2019
This pull request was closed.
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.

5 participants