Skip to content
This repository has been archived by the owner on Jan 22, 2024. It is now read-only.

Add a workflow status badge #1

Open
hectorsector opened this issue Feb 4, 2021 · 3 comments
Open

Add a workflow status badge #1

hectorsector opened this issue Feb 4, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@hectorsector
Copy link
Member

Suggested by @jonlipsky on Slack:

a “build badge” in the readme (main page) of the repo to know if you’ve successfully completed the exercise

For this lab it might be a little tricker; we're asking the learner to perform their actions on branches other than main. When configuring the workflow badge I'm not sure how we'd display the badge for a branch that's not yet created but maybe there's something that's not obvious to me that @mattdavis0351 can see.

Screen Shot 2021-02-04 at 9 56 14 AM

@hectorsector hectorsector added the enhancement New feature or request label Feb 4, 2021
@a-a-ron
Copy link

a-a-ron commented Feb 4, 2021

Hey @hectorsector, I think I got this to work. I'll run through it after our daily standup to make sure.

We need to change the workflow name from Grading workflow to Grading-workflow, and then add the following to the README:

[![Grading-workflow Actions Status](https://github.com/{userName}/{repoName}/workflows/{workflowName}/badge.svg?branch=my-workflows)](https://github.com/{userName}/{repoName}/actions)

Of course, this would need the ability to use environment variables which could result in another action since we don't really have a way to do that easily ... thinking of alternatives 🤔

@hectorsector
Copy link
Member Author

Thanks for this, @a-a-ron!

I'm holding off on this since we don't have an easy way to replace or use variables for the user and repo name fields in the URL.

@mattdavis0351
Copy link
Contributor

@hectorsector we may be able to address this through the API somehow. I think the bigger question would be which piece of the lab is responsible for this? Should Looking Glass set this status badge or should it exist at the template repo level and get updated by workflow check suite state?

I think figuring out if we can do this via API first will help answer those questions

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants