UMM-CSci-3601 / intro-to-git

A group exercise practicing with various git ideas and tools
MIT License
2 stars 7 forks source link

Use new GH Actions badge format #86

Closed helloworld12321 closed 2 years ago

helloworld12321 commented 2 years ago

Closes #81.

helloworld12321 commented 2 years ago

Thanks very much! :)

Do we want to add the ?event= component?

TBH, I'm not sure I fully get what they're saying there. Do badges automatically reflect the state of the branch you're looking at? Or does adding this cause that to happen? If so, it might be nice to have it reflect the state of the branch you're looking at?

I just checked—It looks like badges show the state of the main branch, not the current branch:

screenshot of GitHub where a feature branch is selected, but the badges show the state of the main branch

If you want to show the state of some other branch—for example, if you have a staging branch that's important to you—you can ask for that using a ?branch=staging query parameter. From quickly looking at the docs, I don't think there's a way to specify "always show the state of the current branch", unfortunately. 🤷🏻‍♂️

The ?event= query parameter, by contrast, deals with what sort of event triggered the CI.

For example, maybe you run the CI on pushes and releases, but you only want the releases to be reflected in the badge. Then you could say something like ?event=release, I think.

NicMcPhee commented 2 years ago

Thanks for figuring all that out! I think the default will do just fine for now. 😄