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

Include action name in default message #64

Closed
Cyberbeni opened this issue Oct 7, 2020 · 9 comments
Closed

Include action name in default message #64

Cyberbeni opened this issue Oct 7, 2020 · 9 comments
Assignees
Labels
good first issue Good for newcomers type: feature New feature or feature request
Projects

Comments

@Cyberbeni
Copy link
Contributor

I think this would be useful for people.

@EndBug EndBug self-assigned this Oct 7, 2020
@EndBug EndBug added the type: feature New feature or feature request label Oct 7, 2020
@EndBug EndBug added this to To do in Main board via automation Oct 7, 2020
@EndBug
Copy link
Owner

EndBug commented Oct 7, 2020

You're probably right, thanks for the issue!

@EndBug
Copy link
Owner

EndBug commented Oct 7, 2020

What about Commit from GitHub Actions (EndBug/add-and-commit), is it ok?

@EndBug EndBug added the good first issue Good for newcomers label Oct 7, 2020
@Cyberbeni
Copy link
Contributor Author

I mean using the name of the workflow/job(maybe even step) that it was used from, so for example it would default to Commit from GitHub Actions (Build/Build compiled JS version) when used here:

- uses: EndBug/add-and-commit@v4

Based on this, GITHUB_WORKFLOW env var is available. (I don't know if the job/step name is available)

@EndBug
Copy link
Owner

EndBug commented Oct 7, 2020

Oh, I get it. I'll take a look and see what I can do then 👍

@EndBug
Copy link
Owner

EndBug commented Oct 7, 2020

It seems like the GITHUB_WORKFLOW is accessible as a variable, but the actual job that's running can only be accessed via the github context: that means if you write ${{ github.job }} inside the commit message parameter it will be parsed, but I don't think I can access it, since it's not an env variable.

What about Commit from GitHub Actions ($GITHUB_WORKFLOW) then?

@Cyberbeni
Copy link
Contributor Author

Sounds good, most of the use cases will be clearly recognizable just by the workflow name (And you can still specify your own message if you need to commit multiple times inside a workflow and want to make them easily distinguishable)

EndBug added a commit that referenced this issue Oct 7, 2020
@EndBug
Copy link
Owner

EndBug commented Oct 7, 2020

@all-contributors add @Cyberbeni for ideas

@allcontributors
Copy link
Contributor

@EndBug

I've put up a pull request to add @Cyberbeni! 🎉

@EndBug
Copy link
Owner

EndBug commented Oct 7, 2020

Ok, the change is published in v5.1.0 (mirrored by v5 and latest)
Thanks again for the issue ;)

@EndBug EndBug closed this as completed Oct 7, 2020
Main board automation moved this from To do to Done Oct 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers type: feature New feature or feature request
Projects
No open projects
Main board
  
Done
Development

No branches or pull requests

2 participants