From 6ffe8a468780bc67397f263b388b560d819564a5 Mon Sep 17 00:00:00 2001 From: Stuart Douglas Date: Tue, 18 Jun 2024 11:23:12 +1000 Subject: [PATCH] Rename task-generator --- .github/workflows/check-buildah-remote.yaml | 2 +- .github/workflows/go-ci.yaml | 14 +++++++------- hack/generate-buildah-remote.sh | 8 ++++---- {remote-task-generator => task-generator}/go.mod | 2 +- {remote-task-generator => task-generator}/go.sum | 0 .../remote}/main.go | 0 6 files changed, 13 insertions(+), 13 deletions(-) rename {remote-task-generator => task-generator}/go.mod (98%) rename {remote-task-generator => task-generator}/go.sum (100%) rename {remote-task-generator => task-generator/remote}/main.go (100%) diff --git a/.github/workflows/check-buildah-remote.yaml b/.github/workflows/check-buildah-remote.yaml index df4bb6969b..e1366a3861 100644 --- a/.github/workflows/check-buildah-remote.yaml +++ b/.github/workflows/check-buildah-remote.yaml @@ -11,7 +11,7 @@ jobs: - name: Install Go uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5 with: - go-version-file: './remote-task-generator/go.mod' + go-version-file: './task-generator/go.mod' - name: Check buildah remote run: | ./hack/generate-buildah-remote.sh diff --git a/.github/workflows/go-ci.yaml b/.github/workflows/go-ci.yaml index e965fccb0f..ca7b530e8b 100644 --- a/.github/workflows/go-ci.yaml +++ b/.github/workflows/go-ci.yaml @@ -10,11 +10,11 @@ jobs: - uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 - uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 with: - go-version-file: './remote-task-generator/go.mod' + go-version-file: './task-generator/go.mod' - name: golangci-lint uses: golangci/golangci-lint-action@3cfe3a4abbb849e10058ce4af15d205b6da42804 with: - working-directory: remote-task-generator + working-directory: task-generator args: "--timeout=10m --build-tags='normal periodic'" go: name: Check sources @@ -24,9 +24,9 @@ jobs: - name: Install Go uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 with: - go-version-file: './remote-task-generator/go.mod' + go-version-file: './task-generator/go.mod' - name: Check go mod status - working-directory: remote-task-generator + working-directory: task-generator run: | go mod tidy if [[ ! -z $(git status -s) ]] @@ -36,9 +36,9 @@ jobs: exit 1 fi - name: Check format - working-directory: remote-task-generator + working-directory: task-generator run: | - go fmt + go fmt ./** if [[ ! -z $(git status -s) ]] then @@ -54,7 +54,7 @@ jobs: - uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 - uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 with: - go-version-file: './remote-task-generator/go.mod' + go-version-file: './task-generator/go.mod' # https://github.com/securego/gosec/blob/12be14859bc7d4b956b71bef0b443694aa519d8a/README.md#integrating-with-code-scanning - name: Run Gosec Security Scanner uses: securego/gosec@master diff --git a/hack/generate-buildah-remote.sh b/hack/generate-buildah-remote.sh index 9eb4bfc85c..ffbd943422 100755 --- a/hack/generate-buildah-remote.sh +++ b/hack/generate-buildah-remote.sh @@ -2,11 +2,11 @@ SCRIPTDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" -cd $SCRIPTDIR/../remote-task-generator -go build -o /tmp/generator ./main.go +cd $SCRIPTDIR/../task-generator +go build -o /tmp/remote-generator ./remote/main.go -/tmp/generator --buildah-task=$SCRIPTDIR/../task/buildah/0.1/buildah.yaml \ +/tmp/remote-generator --buildah-task=$SCRIPTDIR/../task/buildah/0.1/buildah.yaml \ --remote-task=$SCRIPTDIR/../task/buildah-remote/0.1/buildah-remote.yaml -/tmp/generator --buildah-task=$SCRIPTDIR/../task/buildah-oci-ta/0.1/buildah-oci-ta.yaml \ +/tmp/remote-generator --buildah-task=$SCRIPTDIR/../task/buildah-oci-ta/0.1/buildah-oci-ta.yaml \ --remote-task=$SCRIPTDIR/../task/buildah-remote-oci-ta/0.1/buildah-remote-oci-ta.yaml diff --git a/remote-task-generator/go.mod b/task-generator/go.mod similarity index 98% rename from remote-task-generator/go.mod rename to task-generator/go.mod index 525b4b02dd..10a38336b1 100644 --- a/remote-task-generator/go.mod +++ b/task-generator/go.mod @@ -1,4 +1,4 @@ -module github.com/konflux-ci/build-definitions/remote-task-generator +module github.com/konflux-ci/build-definitions/task-generator go 1.21 diff --git a/remote-task-generator/go.sum b/task-generator/go.sum similarity index 100% rename from remote-task-generator/go.sum rename to task-generator/go.sum diff --git a/remote-task-generator/main.go b/task-generator/remote/main.go similarity index 100% rename from remote-task-generator/main.go rename to task-generator/remote/main.go