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

Automate collection of GitHub id by name from CI workflows #156

Open
tomwillis608 opened this issue Jun 30, 2023 · 4 comments
Open

Automate collection of GitHub id by name from CI workflows #156

tomwillis608 opened this issue Jun 30, 2023 · 4 comments
Labels
enhancement New feature or request needs refinement An idea that needs to be refined into user stories or chores

Comments

@tomwillis608
Copy link
Collaborator

tomwillis608 commented Jun 30, 2023

The current manual process for finding the workflow ID is cumbersome.

Make it so you just need the name or something easier.

See also @basiliskus comment in #134

@tomwillis608 tomwillis608 added enhancement New feature or request needs refinement An idea that needs to be refined into user stories or chores labels Jun 30, 2023
@tomwillis608
Copy link
Collaborator Author

This may be good news. We currently call gh.get_workflow(id) but it the docs suggest we can also pass in a filename instead of the integer id.

If the deployment action under stud is in .github/workflows/ci-cd-workflow.yaml we should be able to replace the numberic value with the string ci-cd-workflow.yaml.

Testing TBD

@tomwillis608
Copy link
Collaborator Author

Validated that passing the workflow filename instead of the numeric id does yield the same results for a CDC TI workflow.

@tomwillis608
Copy link
Collaborator Author

What I discovered is that there is a solution without a code change if the id value in the config file is given the name of the workflow file, e.g. cicd.yaml , instead of the numeric ID value.
So the first refactor would just change the docs and maybe some comments to tell the user to put the filename of the workflow in the id value in the config file.
But now we have a sloppy configuration variable, which should have a name like workflow_filename or filename , and refactoring by renaming the variable name throughout. Refactor 2.

Go with refactor 2 after discussion with CDC team

@tomwillis608
Copy link
Collaborator Author

Implemented in #508

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request needs refinement An idea that needs to be refined into user stories or chores
Projects
None yet
Development

No branches or pull requests

1 participant