-
Notifications
You must be signed in to change notification settings - Fork 28
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
Ability to add buttons in the publishChecks pipeline step #74
Comments
do you mean the actions in GitHub checks API? And when you click on that button, a request from GitHub will be sent to your Jenkins? May I ask what are you going to use it for? |
@XiongKezhi yes, I actually meant to put this on jenkinsci/github-checks-plugin (I had both tabs open). Oops. There could be any number of reasons to add actions. Perhaps someone builds debug by default as a PR check, but sometimes they want a release build (or vice versa). Maybe it annotated a couple lines which can be auto-fixed with a "Fix these" action, etc. |
I'm planning to implement this, along with #28. But the only thing we can do is no more than exposing the API to add action buttons, the handlers/subscribers for those actions still need the implementation from the users themselves, like https://github.com/jenkinsci/github-checks-plugin/blob/master/src/main/java/io/jenkins/plugins/checks/github/CheckRunGHEventSubscriber.java. |
A use case that may be relevant: I have a Jenkins job that builds HTML documentation and publishes it to a web server (as opposed to having Jenkins serve it). I'd like to post the web server address to the SCM system as part of a checks report, so that I can browse to it without going through Jenkins. However, the SCM is not GitHub and does not support Markdown in the report. Instead, it supports links that have a title and a URL. If I could have the Jenkinsfile generate the web site URL and publish that via Checks API as if it were an action, then that would be cool. Thus, I hope that the actions API being added will allow URLs that do not point to Jenkins. It would be even better if I could make the link part of the checks report that is already published by another plugin, rather than a separate report. I imagine the |
If only considering GitHub, this is not possible. The action for GitHub is just adding buttons to the checks report and used for users to require additional behavior that is pre-defined in Jenkins. But since we are now at the API level and as you said, the SCM is not GitHub, so we can discuss and define a wider-scoped API (not only in this action part) for users if we can have a better abstraction beyond the GitHub one.
This could be done, and yes, this requires changes of the consumers. But if we want to forcefully change the link published by consumers, maybe we need another step, since it's not our purpose of the |
There are a few possible improvements:
I should file separate requests for those, I guess. |
The basic functionality to add action buttons is fixed by #85. |
It would be nice to be able to add buttons to the
publishChecks
pipeline step.The text was updated successfully, but these errors were encountered: