-
Name Previous Value Current Value Type
Question
Bug
Affected Versions
empty 15.1.6
-
Name Previous Value Current Value Type
Bug
Question
-
The groovy script is mainly used in two places:
- Used in issue custom field or build param to calculate choices or default value if hard-code values is not sufficient
- Used in various CI/CD job properties (for instance image or command field of a command step) to insert calcualted string via property interpolation syntax
@scripts:<script name>@
-
Closing. Feel free to reopen if you have more questions
-
Previous Value Current Value Open
Closed
-
Well, I was thinking to script an auto-comment on the issue whenever a commit was received. But that might be a bit out of scope I reckon. Or would it still be possible?
For now I created a cronjob that monitors the commits and posts a comment, mentioning the commit, via the API. Basicly mimicking the functionality that was once added and later removed again :-) Thinking to change it into a webhook listener tho.
-
Previous Value Current Value Closed
Open
-
updated so it is now using a job executor (server shell). A trigger set via .onedev-buildspec.yml executes a shell script on trigger "BranchUpdateTrigger". Params passing along the project_path and commit hash. The script filters the commit message for an issue #nr. Then uses the api to get the internal issueId to post the comment (via api), as a service user, stating the commit done by (the author) with a link to the diff commit. Will look into converting this python script into a groovy script.
-
OneDev tracks commits associated with issues automatically if the commit message contains something like this:
Fixes #<issue number>And the result is:
https://code.onedev.io/onedev/server/~issues/2813/commits
The commit message pattern to fix a issue number can be customized via
Administration / Issue Settings / Commit Message Fix Settings -
yes, that is a nice feature. But we're just really used to see how the flow inside an issue is with comments and commits in chronological order. And having the commit-comments in them is also helpful. Maybe it would be feasible to include that "fixing commits" tab like a toggle, just like activities and comments. Commit comments would then finish it off :-)
But we're not hoping or waiting for that and implemented this workaround which works well enough. -
I am closing this as I cannot help more on this.
-
Previous Value Current Value Open
Closed
| Type |
Question
|
| Priority |
Normal
|
| Assignee | |
| Labels |
No labels
|
I have made and have some ideas todo for groovy script, but I cant seem to figure out how to get the scripts running. In admin -> groovyscripting I made a script to test a bit. How does the script get triggered to run. I thought there would be a "run" button or something. And/or trigger the scripts from a job configured in .onedev-buildspec.yml. But I dont see them listed in the "steps".
Are there any examples or hints as how to trigger these scripts?