diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 99774bc..12d571e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -10,27 +10,9 @@ include: # linting - component: "$CI_SERVER_FQDN/components/golanglint/golanglint@v1.0.0" - inputs: - stage: "linting" -testing: - stage: "testing" - needs: - - "linting" - image: "cr.simoncor.net/siempie/go-build:latest" - script: - - "go test cmd/gogitlabber/*.go" + # testing + - local: ".gitlab/testing.yaml" -releasing: - stage: "releasing" - needs: - - "testing" - image: - name: "goreleaser/goreleaser:v2.10.2" - entrypoint: [""] - rules: - - if: '$CI_COMMIT_TAG' - variables: - GITLAB_TOKEN: '$GORELEASER_GITLAB_TOKEN' - script: - - "goreleaser release --clean" + # releaseing + - local: ".gitlab/releasing.yaml" diff --git a/.gitlab/releasing.yaml b/.gitlab/releasing.yaml new file mode 100644 index 0000000..abffc64 --- /dev/null +++ b/.gitlab/releasing.yaml @@ -0,0 +1,15 @@ +--- + +releasing: + stage: "releasing" + needs: + - "testing" + image: + name: "goreleaser/goreleaser:v2.10.2" + entrypoint: [""] + rules: + - if: '$CI_COMMIT_TAG' + variables: + GITLAB_TOKEN: '$GORELEASER_GITLAB_TOKEN' + script: + - "goreleaser release --clean" diff --git a/.gitlab/testing.yaml b/.gitlab/testing.yaml new file mode 100644 index 0000000..6eca83f --- /dev/null +++ b/.gitlab/testing.yaml @@ -0,0 +1,9 @@ +--- + +testing: + stage: "testing" + needs: + - "linting" + image: "cr.simoncor.net/siempie/go-build:latest" + script: + - "go test cmd/gogitlabber/*.go"