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

Fix capture-build-details.sh to work with detached state or tags #378

Merged
merged 1 commit into from
Aug 11, 2024

Conversation

dnzxy
Copy link
Contributor

@dnzxy dnzxy commented Aug 10, 2024

Fixes build so that Trio can be built from a detached state (single commit checked out) or tags.

Thank you @bjorkert 🙏

Co-Authored-By: Jonas Björkert <bjorkert@users.noreply.github.com>
Copy link
Contributor

@Sjoerd-Bo3 Sjoerd-Bo3 left a comment

Choose a reason for hiding this comment

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

Code looks solid. Doesn’t break previous behaviour. Just adds an option for detached.

@marionbarker
Copy link
Contributor

Status

Success

Tested building a detached HEAD

Background

Previously when checking out an earlier commit of a given branch and leaving it as a detached HEAD, the capture-build-details.sh failed when trying to build because there was no branch.

Test

Update local clone to

  • 8811afe0 (dnzxy/fix-capture-build) Fix capture-build-details.sh to work with detached state or tags
  • test that build succeeds
  • add empty commit to advance the SHA for the branch (in local clone)
git commit --allow-empty -m "empty commit"
  • checkout a detached HEAD pointing to 8811afe0
git checkout 8811afe0
xed .

Build was successful

  • Trio, Settings indicates: branch: detached 8811afe

@marionbarker marionbarker self-requested a review August 11, 2024 01:46
@bjornoleh
Copy link
Contributor

Merging with two approvals.

@bjornoleh bjornoleh merged commit c8385cc into nightscout:dev Aug 11, 2024
1 check passed
@MikePlante1 MikePlante1 mentioned this pull request Aug 17, 2024
mountrcg pushed a commit to mountrcg/Trio that referenced this pull request Sep 11, 2024
Fix capture-build-details.sh to work with detached state or tags
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants