[RFC] Jenkinsfile: reduce duplicated code by defining some functions#39708
[RFC] Jenkinsfile: reduce duplicated code by defining some functions#39708thaJeztah wants to merge 2 commits intomoby:masterfrom
Conversation
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
|
ok, first attempt didn't work |
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
| @@ -1,4 +1,45 @@ | |||
| #!groovy | |||
|
|
|||
| void printInfo() { | |||
There was a problem hiding this comment.
I tried to move this to a separate file (which might be possible, but let's discuss first if we like the approach)
|
@andrewhsu @tiborvass wdyt of an approach like this? |
|
@thaJeztah I think that I would not oppose this, but I would much rather go away from Jenkinsfile as much as possible, so that we can simply call make targets instead, the same ones that would be called in CI from Jenkinsfile. |
|
@tiborvass agreed; we should try to move things to the makefile as much as possible. Not sure how we'll deal with Windows (without having There might still be CI-specific steps (not sure if we want those in the makefile) I can close this one for now, as it was mainly a PoC / quick attempt |
|
@thaJeztah we could either leverage bash on windows, or start converting bash to Go. |
|
(not related to testing, but also thinking how important it is to support build everything outside of a container, or if we can start inlining things in the dockerfile) |
not sure if this works, but an attempt at reducing a lot of duplication in our Jenkinsfile