Skip to content

Add get-git-ref-info action, update READMEs#39

Merged
CodeGat merged 3 commits intomainfrom
add-get-git-ref-info-action
Oct 29, 2025
Merged

Add get-git-ref-info action, update READMEs#39
CodeGat merged 3 commits intomainfrom
add-get-git-ref-info-action

Conversation

@CodeGat
Copy link
Copy Markdown
Member

@CodeGat CodeGat commented Oct 28, 2025

Background

In build-cd, I require knowing whether a given git ref is a branch, tag or commit (as a later spack repo update command has the flags --commit, --branch and --tag rather than something nice like --ref).

However, this need seems to be a bit more universal than just build-cd, so I've turned it into an action under this repository, instead!

The PR

  • Add get-git-ref-info action that checks out a given repository, then looks if a given ref is a branch, tag or commit, and returns the equivalent SHA if it exists.
  • Add action README.md
  • Update root README.md

Testing

Done in https://github.com/codegat-test-org/test/actions/runs/18865197415/job/53831413357

@CodeGat CodeGat added the enhancement New feature or request label Oct 28, 2025
@CodeGat CodeGat self-assigned this Oct 28, 2025
@CodeGat CodeGat added the enhancement New feature or request label Oct 28, 2025
@CodeGat CodeGat moved this from New Issues 🌅 to In Progress 🏗️ in Spack `0.22` to `1.0` Migration Oct 28, 2025
@CodeGat CodeGat force-pushed the add-get-git-ref-info-action branch from c7c49a1 to b3fa027 Compare October 28, 2025 05:33
@CodeGat CodeGat marked this pull request as ready for review October 29, 2025 00:38
@CodeGat CodeGat moved this from In Progress 🏗️ to Review 👏 in Spack `0.22` to `1.0` Migration Oct 29, 2025
@atteggiani atteggiani self-requested a review October 29, 2025 00:42
Copy link
Copy Markdown
Collaborator

@atteggiani atteggiani left a comment

Choose a reason for hiding this comment

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

Looks good.

I left a few minor fixes and suggestions in the README and action.

@CodeGat CodeGat requested a review from atteggiani October 29, 2025 01:42
Copy link
Copy Markdown
Collaborator

@atteggiani atteggiani left a comment

Choose a reason for hiding this comment

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

Looks good!

@CodeGat CodeGat merged commit b396eba into main Oct 29, 2025
@github-project-automation github-project-automation bot moved this from Review 👏 to Done ✅ in Spack `0.22` to `1.0` Migration Oct 29, 2025
@CodeGat CodeGat deleted the add-get-git-ref-info-action branch October 29, 2025 04:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

Status: Done ✅

Development

Successfully merging this pull request may close these issues.

2 participants