From 394aaf6b05fc9706a530795bccbaff6e7f6463d8 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 11:57:59 -0800 Subject: [PATCH 01/21] remove breaking github actions --- .goreleaser.yml | 188 ++++++++++++++++++++++++------------------------ 1 file changed, 94 insertions(+), 94 deletions(-) diff --git a/.goreleaser.yml b/.goreleaser.yml index ac6f3ee9..d7614001 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -2,8 +2,8 @@ version: 2 dist: releases release: github: - owner: ekristen - name: aws-nuke + owner: oreillymedia + name: aws-nuke-v2 builds: - id: default env: @@ -35,95 +35,95 @@ builds: - -X '{{ .ModulePath }}/pkg/common.BRANCH={{ .Branch }}' - -X '{{ .ModulePath }}/pkg/common.VERSION={{ .Tag }}' - -X '{{ .ModulePath }}/pkg/common.COMMIT={{ .Commit }}' - hooks: - post: - - cmd: | - {{- if eq .Os "darwin" -}} - quill sign-and-notarize "{{ .Path }}" --dry-run={{ .IsSnapshot }} --ad-hoc={{ .IsSnapshot }} -vv - {{- else -}} - true - {{- end -}} - env: - - QUILL_LOG_FILE=/tmp/quill-{{ .Target }}.log -archives: - - id: default - builds: - - default - name_template: "{{ .ProjectName }}-v{{ .Version }}-{{ .Os }}-{{ .Arch }}{{ .Arm }}" - format_overrides: - - goos: windows - format: zip -dockers: - - use: buildx - goos: linux - goarch: amd64 - dockerfile: Dockerfile - image_templates: - - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-amd64 - build_flag_templates: - - "--target=goreleaser" - - "--pull" - - "--label=org.opencontainers.image.created={{.Date}}" - - "--label=org.opencontainers.image.title={{.ProjectName}}" - - "--label=org.opencontainers.image.revision={{.FullCommit}}" - - "--label=org.opencontainers.image.version={{.Version}}" - - "--label=org.opencontainers.image.source=https://github.com/ekristen/aws-nuke" - - "--platform=linux/amd64" - - use: buildx - goos: linux - goarch: arm64 - dockerfile: Dockerfile - image_templates: - - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm64 - build_flag_templates: - - "--platform=linux/arm64" - - "--target=goreleaser" - - "--pull" - - "--label=org.opencontainers.image.created={{.Date}}" - - "--label=org.opencontainers.image.title={{.ProjectName}}" - - "--label=org.opencontainers.image.revision={{.FullCommit}}" - - "--label=org.opencontainers.image.version={{.Version}}" - - '--label=org.opencontainers.image.source={{replace (replace (replace .GitURL "git@" "https://") ".git" "") "github.com:" "github.com/"}}' - - use: buildx - goos: linux - goarch: arm - goarm: "7" - dockerfile: Dockerfile - image_templates: - - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm32v7 - build_flag_templates: - - "--platform=linux/arm/v7" - - "--target=goreleaser" - - "--pull" - - "--label=org.opencontainers.image.created={{.Date}}" - - "--label=org.opencontainers.image.title={{.ProjectName}}" - - "--label=org.opencontainers.image.revision={{.FullCommit}}" - - "--label=org.opencontainers.image.version={{.Version}}" - - '--label=org.opencontainers.image.source={{replace (replace (replace .GitURL "git@" "https://") ".git" "") "github.com:" "github.com/"}}' -docker_manifests: - - use: docker - name_template: ghcr.io/ekristen/aws-nuke:v{{ .Version }} - image_templates: - - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-amd64 - - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm64 - - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm32v7 -signs: - - ids: - - default - cmd: cosign - signature: "${artifact}.sig" - certificate: "${artifact}.pem" - args: ["sign-blob", "--yes", "--oidc-provider=github", "--oidc-issuer=https://token.actions.githubusercontent.com", "--output-certificate=${certificate}", "--output-signature=${signature}", "${artifact}"] - artifacts: all -docker_signs: - - ids: - - default - artifacts: all - cmd: cosign - args: ["sign", "--yes", "--oidc-provider=github", "--oidc-issuer=https://token.actions.githubusercontent.com", "--output-certificate=${certificate}", "--output-signature=${signature}", "${artifact}"] -checksum: - name_template: "checksums.txt" -snapshot: - name_template: '{{ trimprefix .Summary "v" }}' -changelog: - disable: true + # hooks: + # post: + # - cmd: | + # {{- if eq .Os "darwin" -}} + # quill sign-and-notarize "{{ .Path }}" --dry-run={{ .IsSnapshot }} --ad-hoc={{ .IsSnapshot }} -vv + # {{- else -}} + # true + # {{- end -}} + # env: + # - QUILL_LOG_FILE=/tmp/quill-{{ .Target }}.log +# archives: +# - id: default +# builds: +# - default +# name_template: "{{ .ProjectName }}-v{{ .Version }}-{{ .Os }}-{{ .Arch }}{{ .Arm }}" +# format_overrides: +# - goos: windows +# format: zip +# dockers: +# - use: buildx +# goos: linux +# goarch: amd64 +# dockerfile: Dockerfile +# image_templates: +# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-amd64 +# build_flag_templates: +# - "--target=goreleaser" +# - "--pull" +# - "--label=org.opencontainers.image.created={{.Date}}" +# - "--label=org.opencontainers.image.title={{.ProjectName}}" +# - "--label=org.opencontainers.image.revision={{.FullCommit}}" +# - "--label=org.opencontainers.image.version={{.Version}}" +# - "--label=org.opencontainers.image.source=https://github.com/ekristen/aws-nuke" +# - "--platform=linux/amd64" +# - use: buildx +# goos: linux +# goarch: arm64 +# dockerfile: Dockerfile +# image_templates: +# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm64 +# build_flag_templates: +# - "--platform=linux/arm64" +# - "--target=goreleaser" +# - "--pull" +# - "--label=org.opencontainers.image.created={{.Date}}" +# - "--label=org.opencontainers.image.title={{.ProjectName}}" +# - "--label=org.opencontainers.image.revision={{.FullCommit}}" +# - "--label=org.opencontainers.image.version={{.Version}}" +# - '--label=org.opencontainers.image.source={{replace (replace (replace .GitURL "git@" "https://") ".git" "") "github.com:" "github.com/"}}' +# - use: buildx +# goos: linux +# goarch: arm +# goarm: "7" +# dockerfile: Dockerfile +# image_templates: +# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm32v7 +# build_flag_templates: +# - "--platform=linux/arm/v7" +# - "--target=goreleaser" +# - "--pull" +# - "--label=org.opencontainers.image.created={{.Date}}" +# - "--label=org.opencontainers.image.title={{.ProjectName}}" +# - "--label=org.opencontainers.image.revision={{.FullCommit}}" +# - "--label=org.opencontainers.image.version={{.Version}}" +# - '--label=org.opencontainers.image.source={{replace (replace (replace .GitURL "git@" "https://") ".git" "") "github.com:" "github.com/"}}' +# docker_manifests: +# - use: docker +# name_template: ghcr.io/ekristen/aws-nuke:v{{ .Version }} +# image_templates: +# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-amd64 +# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm64 +# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm32v7 +# signs: +# - ids: +# - default +# cmd: cosign +# signature: "${artifact}.sig" +# certificate: "${artifact}.pem" +# args: ["sign-blob", "--yes", "--oidc-provider=github", "--oidc-issuer=https://token.actions.githubusercontent.com", "--output-certificate=${certificate}", "--output-signature=${signature}", "${artifact}"] +# artifacts: all +# docker_signs: +# - ids: +# - default +# artifacts: all +# cmd: cosign +# args: ["sign", "--yes", "--oidc-provider=github", "--oidc-issuer=https://token.actions.githubusercontent.com", "--output-certificate=${certificate}", "--output-signature=${signature}", "${artifact}"] +# checksum: +# name_template: "checksums.txt" +# snapshot: +# name_template: '{{ trimprefix .Summary "v" }}' +# changelog: +# disable: true From d14c69b2e4912e49de8cd6bec9da3eeb9dd23a27 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 13:44:00 -0800 Subject: [PATCH 02/21] only run commit-lint and semantic-lint for upstream repo --- .github/workflows/commit-lint.yaml | 1 + .github/workflows/semantic-lint.yml | 1 + 2 files changed, 2 insertions(+) diff --git a/.github/workflows/commit-lint.yaml b/.github/workflows/commit-lint.yaml index e83fcf5c..61217b50 100644 --- a/.github/workflows/commit-lint.yaml +++ b/.github/workflows/commit-lint.yaml @@ -13,6 +13,7 @@ permissions: jobs: commit-lint: + if: github.repository == 'ekristen/aws-nuke' name: commit-lint runs-on: ubuntu-latest steps: diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index e3d85576..d4ef5da8 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,6 +13,7 @@ permissions: jobs: semantic-lint: + if: github.repository == 'ekristen/aws-nuke' runs-on: ubuntu-latest steps: - uses: amannn/action-semantic-pull-request@v5 From 8cd7bf3f787e2ef4f0e164aa69ed8b767c0f9b3a Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 13:48:20 -0800 Subject: [PATCH 03/21] update syntax for github action --- .github/workflows/commit-lint.yaml | 2 +- .github/workflows/semantic-lint.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/commit-lint.yaml b/.github/workflows/commit-lint.yaml index 61217b50..e48599d1 100644 --- a/.github/workflows/commit-lint.yaml +++ b/.github/workflows/commit-lint.yaml @@ -13,7 +13,7 @@ permissions: jobs: commit-lint: - if: github.repository == 'ekristen/aws-nuke' + if: ${{ github.repository == 'ekristen/aws-nuke' }} name: commit-lint runs-on: ubuntu-latest steps: diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index d4ef5da8..e86d9a79 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,7 +13,7 @@ permissions: jobs: semantic-lint: - if: github.repository == 'ekristen/aws-nuke' + if: ${{ github.repository == 'ekristen/aws-nuke' }} runs-on: ubuntu-latest steps: - uses: amannn/action-semantic-pull-request@v5 From fe640017e94695b6eb2c85fbe82a3c34157d5591 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 13:54:27 -0800 Subject: [PATCH 04/21] update order of condition check for github action --- .github/workflows/commit-lint.yaml | 5 +++-- .github/workflows/semantic-lint.yml | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/commit-lint.yaml b/.github/workflows/commit-lint.yaml index e48599d1..4bac1c5a 100644 --- a/.github/workflows/commit-lint.yaml +++ b/.github/workflows/commit-lint.yaml @@ -13,9 +13,10 @@ permissions: jobs: commit-lint: - if: ${{ github.repository == 'ekristen/aws-nuke' }} name: commit-lint runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: wagoid/commitlint-github-action@v6 \ No newline at end of file + if: ${{ github.repository == 'ekristen/aws-nuke' }} + - uses: wagoid/commitlint-github-action@v6 + if: ${{ github.repository == 'ekristen/aws-nuke' }} \ No newline at end of file diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index e86d9a79..60d24d68 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,9 +13,9 @@ permissions: jobs: semantic-lint: - if: ${{ github.repository == 'ekristen/aws-nuke' }} runs-on: ubuntu-latest steps: - uses: amannn/action-semantic-pull-request@v5 + if: ${{ github.repository == 'ekristen/aws-nuke' }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 8d1462f58ef65f22795e9c532df0d7ace218b90b Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 13:56:03 -0800 Subject: [PATCH 05/21] update syntax for github action --- .github/workflows/commit-lint.yaml | 4 ++-- .github/workflows/semantic-lint.yml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/commit-lint.yaml b/.github/workflows/commit-lint.yaml index 4bac1c5a..136792b6 100644 --- a/.github/workflows/commit-lint.yaml +++ b/.github/workflows/commit-lint.yaml @@ -17,6 +17,6 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - if: ${{ github.repository == 'ekristen/aws-nuke' }} + if: github.repository == 'ekristen/aws-nuke' - uses: wagoid/commitlint-github-action@v6 - if: ${{ github.repository == 'ekristen/aws-nuke' }} \ No newline at end of file + if: github.repository == 'ekristen/aws-nuke' \ No newline at end of file diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index 60d24d68..b48a61bd 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -16,6 +16,6 @@ jobs: runs-on: ubuntu-latest steps: - uses: amannn/action-semantic-pull-request@v5 - if: ${{ github.repository == 'ekristen/aws-nuke' }} + if: github.repository == 'ekristen/aws-nuke' env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From fa9af92501b61c3bc6b3ac6888f262003a95c790 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:05:13 -0800 Subject: [PATCH 06/21] update order of condition check for github action --- .github/workflows/commit-lint.yaml | 5 ++--- .github/workflows/semantic-lint.yml | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/commit-lint.yaml b/.github/workflows/commit-lint.yaml index 136792b6..61217b50 100644 --- a/.github/workflows/commit-lint.yaml +++ b/.github/workflows/commit-lint.yaml @@ -13,10 +13,9 @@ permissions: jobs: commit-lint: + if: github.repository == 'ekristen/aws-nuke' name: commit-lint runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - if: github.repository == 'ekristen/aws-nuke' - - uses: wagoid/commitlint-github-action@v6 - if: github.repository == 'ekristen/aws-nuke' \ No newline at end of file + - uses: wagoid/commitlint-github-action@v6 \ No newline at end of file diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index b48a61bd..d4ef5da8 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,9 +13,9 @@ permissions: jobs: semantic-lint: + if: github.repository == 'ekristen/aws-nuke' runs-on: ubuntu-latest steps: - uses: amannn/action-semantic-pull-request@v5 - if: github.repository == 'ekristen/aws-nuke' env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 3bbad2e2b2fd8f36c08bac041bd09cf3c039f2e2 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:09:14 -0800 Subject: [PATCH 07/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index d4ef5da8..99c31cc1 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,9 +13,9 @@ permissions: jobs: semantic-lint: - if: github.repository == 'ekristen/aws-nuke' runs-on: ubuntu-latest steps: - - uses: amannn/action-semantic-pull-request@v5 + - if: ${{ github.repository == 'ekristen/aws-nuke' }} + uses: amannn/action-semantic-pull-request@v5 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From c827bbb70020aa80f3018f571166be8ce62dd058 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:19:30 -0800 Subject: [PATCH 08/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index 99c31cc1..60d24d68 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -15,7 +15,7 @@ jobs: semantic-lint: runs-on: ubuntu-latest steps: - - if: ${{ github.repository == 'ekristen/aws-nuke' }} - uses: amannn/action-semantic-pull-request@v5 + - uses: amannn/action-semantic-pull-request@v5 + if: ${{ github.repository == 'ekristen/aws-nuke' }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From ce732e0902e38d4dd4bdf11ab0c3d7333de4e49f Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:22:18 -0800 Subject: [PATCH 09/21] update syntax for github action --- .github/workflows/semantic-lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index 60d24d68..b48a61bd 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -16,6 +16,6 @@ jobs: runs-on: ubuntu-latest steps: - uses: amannn/action-semantic-pull-request@v5 - if: ${{ github.repository == 'ekristen/aws-nuke' }} + if: github.repository == 'ekristen/aws-nuke' env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From b6cb43a6efdbe1da160029916905cddea8a1b672 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:22:53 -0800 Subject: [PATCH 10/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index b48a61bd..e86d9a79 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,9 +13,9 @@ permissions: jobs: semantic-lint: + if: ${{ github.repository == 'ekristen/aws-nuke' }} runs-on: ubuntu-latest steps: - uses: amannn/action-semantic-pull-request@v5 - if: github.repository == 'ekristen/aws-nuke' env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From b27fe18b9255df48147d9304be985e49892517a6 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:23:17 -0800 Subject: [PATCH 11/21] update syntax for github action --- .github/workflows/semantic-lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index e86d9a79..d4ef5da8 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,7 +13,7 @@ permissions: jobs: semantic-lint: - if: ${{ github.repository == 'ekristen/aws-nuke' }} + if: github.repository == 'ekristen/aws-nuke' runs-on: ubuntu-latest steps: - uses: amannn/action-semantic-pull-request@v5 From aa0648d659c62cb6dc5231d12743cac89dc44948 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:25:44 -0800 Subject: [PATCH 12/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index d4ef5da8..5807ed2f 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,8 +13,8 @@ permissions: jobs: semantic-lint: - if: github.repository == 'ekristen/aws-nuke' runs-on: ubuntu-latest + if: github.repository == 'ekristen/aws-nuke' steps: - uses: amannn/action-semantic-pull-request@v5 env: From 97f4d80303c7673a8c5f17910cfc3ac0deb202a8 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:32:15 -0800 Subject: [PATCH 13/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index 5807ed2f..a35cafe1 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -14,7 +14,7 @@ permissions: jobs: semantic-lint: runs-on: ubuntu-latest - if: github.repository == 'ekristen/aws-nuke' + if: ${{ github.repository == 'ekristen/aws-nuke' }} steps: - uses: amannn/action-semantic-pull-request@v5 env: From baa7a8e4358f8168a7a959d28cc3f1e4d8990a53 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:40:24 -0800 Subject: [PATCH 14/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index a35cafe1..d4ef5da8 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,8 +13,8 @@ permissions: jobs: semantic-lint: + if: github.repository == 'ekristen/aws-nuke' runs-on: ubuntu-latest - if: ${{ github.repository == 'ekristen/aws-nuke' }} steps: - uses: amannn/action-semantic-pull-request@v5 env: From 2db46d1d34d8833b3121a739dae8b2175e0635ab Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:57:25 -0800 Subject: [PATCH 15/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index d4ef5da8..3041cf74 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -16,6 +16,8 @@ jobs: if: github.repository == 'ekristen/aws-nuke' runs-on: ubuntu-latest steps: + - name: Print debug information + run: echo "Repository: ${{ github.repository }}" - uses: amannn/action-semantic-pull-request@v5 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 9e52a219daf41707d7f9528d9ca4c408a1123b92 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 14:59:53 -0800 Subject: [PATCH 16/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 38 ++++++++++++++--------------- 1 file changed, 18 insertions(+), 20 deletions(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index 3041cf74..5b190173 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -1,23 +1,21 @@ -name: semantic-lint +# name: semantic-lint -on: - pull_request_target: - types: - - opened - - edited - - synchronize +# on: +# pull_request_target: +# types: +# - opened +# - edited +# - synchronize -permissions: - contents: read - pull-requests: read +# permissions: +# contents: read +# pull-requests: read -jobs: - semantic-lint: - if: github.repository == 'ekristen/aws-nuke' - runs-on: ubuntu-latest - steps: - - name: Print debug information - run: echo "Repository: ${{ github.repository }}" - - uses: amannn/action-semantic-pull-request@v5 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} +# jobs: +# semantic-lint: +# if: github.repository == 'ekristen/aws-nuke' +# runs-on: ubuntu-latest +# steps: +# - uses: amannn/action-semantic-pull-request@v5 +# env: +# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From fc10b1eff9abb682abdd24b7553dac09e18ff584 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 15:07:16 -0800 Subject: [PATCH 17/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index 5b190173..8cd8d4e3 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -18,4 +18,4 @@ # steps: # - uses: amannn/action-semantic-pull-request@v5 # env: -# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} +## GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From a3f15f61a39e3c7e38a7079801aba3476a851b84 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 15:18:56 -0800 Subject: [PATCH 18/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 2 +- .github/workflows/semantic.yml | 70 ++++++++++++++--------------- 2 files changed, 36 insertions(+), 36 deletions(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index 8cd8d4e3..5b190173 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -18,4 +18,4 @@ # steps: # - uses: amannn/action-semantic-pull-request@v5 # env: -## GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} +# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/semantic.yml b/.github/workflows/semantic.yml index 7949f3f1..06055303 100644 --- a/.github/workflows/semantic.yml +++ b/.github/workflows/semantic.yml @@ -1,37 +1,37 @@ -name: semantic -on: - push: - branches: - - main - - next +# name: semantic +# on: +# push: +# branches: +# - main +# - next -permissions: - contents: read # for checkout +# permissions: +# contents: read # for checkout -jobs: - release: - name: release - runs-on: ubuntu-latest - permissions: - contents: write # to be able to publish a GitHub release - issues: write # to be able to comment on released issues - pull-requests: write # to be able to comment on released pull requests - id-token: write # to enable use of OIDC for npm provenance - steps: - - name: checkout - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - name: setup node.js - uses: actions/setup-node@v4 - with: - node-version: "lts/*" - - name: release - env: - GITHUB_TOKEN: ${{ secrets.SEMANTIC_GITHUB_TOKEN }} - run: | - npx \ - -p @semantic-release/commit-analyzer \ - -p @semantic-release/release-notes-generator \ - -p @semantic-release/github \ - semantic-release +# jobs: +# release: +# name: release +# runs-on: ubuntu-latest +# permissions: +# contents: write # to be able to publish a GitHub release +# issues: write # to be able to comment on released issues +# pull-requests: write # to be able to comment on released pull requests +# id-token: write # to enable use of OIDC for npm provenance +# steps: +# - name: checkout +# uses: actions/checkout@v4 +# with: +# fetch-depth: 0 +# - name: setup node.js +# uses: actions/setup-node@v4 +# with: +# node-version: "lts/*" +# - name: release +# env: +# GITHUB_TOKEN: ${{ secrets.SEMANTIC_GITHUB_TOKEN }} +# run: | +# npx \ +# -p @semantic-release/commit-analyzer \ +# -p @semantic-release/release-notes-generator \ +# -p @semantic-release/github \ +# semantic-release From 3427798eb1a2e579222ade82c300b293aa637037 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 15:19:48 -0800 Subject: [PATCH 19/21] update order of condition check for github action --- .github/workflows/semantic-lint.yml | 36 +++++++-------- .github/workflows/semantic.yml | 70 ++++++++++++++--------------- 2 files changed, 53 insertions(+), 53 deletions(-) diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index 5b190173..d4ef5da8 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -1,21 +1,21 @@ -# name: semantic-lint +name: semantic-lint -# on: -# pull_request_target: -# types: -# - opened -# - edited -# - synchronize +on: + pull_request_target: + types: + - opened + - edited + - synchronize -# permissions: -# contents: read -# pull-requests: read +permissions: + contents: read + pull-requests: read -# jobs: -# semantic-lint: -# if: github.repository == 'ekristen/aws-nuke' -# runs-on: ubuntu-latest -# steps: -# - uses: amannn/action-semantic-pull-request@v5 -# env: -# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} +jobs: + semantic-lint: + if: github.repository == 'ekristen/aws-nuke' + runs-on: ubuntu-latest + steps: + - uses: amannn/action-semantic-pull-request@v5 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/semantic.yml b/.github/workflows/semantic.yml index 06055303..7949f3f1 100644 --- a/.github/workflows/semantic.yml +++ b/.github/workflows/semantic.yml @@ -1,37 +1,37 @@ -# name: semantic -# on: -# push: -# branches: -# - main -# - next +name: semantic +on: + push: + branches: + - main + - next -# permissions: -# contents: read # for checkout +permissions: + contents: read # for checkout -# jobs: -# release: -# name: release -# runs-on: ubuntu-latest -# permissions: -# contents: write # to be able to publish a GitHub release -# issues: write # to be able to comment on released issues -# pull-requests: write # to be able to comment on released pull requests -# id-token: write # to enable use of OIDC for npm provenance -# steps: -# - name: checkout -# uses: actions/checkout@v4 -# with: -# fetch-depth: 0 -# - name: setup node.js -# uses: actions/setup-node@v4 -# with: -# node-version: "lts/*" -# - name: release -# env: -# GITHUB_TOKEN: ${{ secrets.SEMANTIC_GITHUB_TOKEN }} -# run: | -# npx \ -# -p @semantic-release/commit-analyzer \ -# -p @semantic-release/release-notes-generator \ -# -p @semantic-release/github \ -# semantic-release +jobs: + release: + name: release + runs-on: ubuntu-latest + permissions: + contents: write # to be able to publish a GitHub release + issues: write # to be able to comment on released issues + pull-requests: write # to be able to comment on released pull requests + id-token: write # to enable use of OIDC for npm provenance + steps: + - name: checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: setup node.js + uses: actions/setup-node@v4 + with: + node-version: "lts/*" + - name: release + env: + GITHUB_TOKEN: ${{ secrets.SEMANTIC_GITHUB_TOKEN }} + run: | + npx \ + -p @semantic-release/commit-analyzer \ + -p @semantic-release/release-notes-generator \ + -p @semantic-release/github \ + semantic-release From 1dea7c1e447a9824216d84dd8732f0679c21b32a Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 15:40:28 -0800 Subject: [PATCH 20/21] remove condition from lint workflows --- .github/workflows/commit-lint.yaml | 1 - .github/workflows/semantic-lint.yml | 1 - 2 files changed, 2 deletions(-) diff --git a/.github/workflows/commit-lint.yaml b/.github/workflows/commit-lint.yaml index 61217b50..e83fcf5c 100644 --- a/.github/workflows/commit-lint.yaml +++ b/.github/workflows/commit-lint.yaml @@ -13,7 +13,6 @@ permissions: jobs: commit-lint: - if: github.repository == 'ekristen/aws-nuke' name: commit-lint runs-on: ubuntu-latest steps: diff --git a/.github/workflows/semantic-lint.yml b/.github/workflows/semantic-lint.yml index d4ef5da8..e3d85576 100644 --- a/.github/workflows/semantic-lint.yml +++ b/.github/workflows/semantic-lint.yml @@ -13,7 +13,6 @@ permissions: jobs: semantic-lint: - if: github.repository == 'ekristen/aws-nuke' runs-on: ubuntu-latest steps: - uses: amannn/action-semantic-pull-request@v5 From 5b60d5e68473a51244e3b3617124408dd0855262 Mon Sep 17 00:00:00 2001 From: Cory Bekker Date: Fri, 10 Jan 2025 15:47:43 -0800 Subject: [PATCH 21/21] removed commented out goreleaser config --- .goreleaser.yml | 92 ------------------------------------------------- 1 file changed, 92 deletions(-) diff --git a/.goreleaser.yml b/.goreleaser.yml index d7614001..310617fb 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -35,95 +35,3 @@ builds: - -X '{{ .ModulePath }}/pkg/common.BRANCH={{ .Branch }}' - -X '{{ .ModulePath }}/pkg/common.VERSION={{ .Tag }}' - -X '{{ .ModulePath }}/pkg/common.COMMIT={{ .Commit }}' - # hooks: - # post: - # - cmd: | - # {{- if eq .Os "darwin" -}} - # quill sign-and-notarize "{{ .Path }}" --dry-run={{ .IsSnapshot }} --ad-hoc={{ .IsSnapshot }} -vv - # {{- else -}} - # true - # {{- end -}} - # env: - # - QUILL_LOG_FILE=/tmp/quill-{{ .Target }}.log -# archives: -# - id: default -# builds: -# - default -# name_template: "{{ .ProjectName }}-v{{ .Version }}-{{ .Os }}-{{ .Arch }}{{ .Arm }}" -# format_overrides: -# - goos: windows -# format: zip -# dockers: -# - use: buildx -# goos: linux -# goarch: amd64 -# dockerfile: Dockerfile -# image_templates: -# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-amd64 -# build_flag_templates: -# - "--target=goreleaser" -# - "--pull" -# - "--label=org.opencontainers.image.created={{.Date}}" -# - "--label=org.opencontainers.image.title={{.ProjectName}}" -# - "--label=org.opencontainers.image.revision={{.FullCommit}}" -# - "--label=org.opencontainers.image.version={{.Version}}" -# - "--label=org.opencontainers.image.source=https://github.com/ekristen/aws-nuke" -# - "--platform=linux/amd64" -# - use: buildx -# goos: linux -# goarch: arm64 -# dockerfile: Dockerfile -# image_templates: -# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm64 -# build_flag_templates: -# - "--platform=linux/arm64" -# - "--target=goreleaser" -# - "--pull" -# - "--label=org.opencontainers.image.created={{.Date}}" -# - "--label=org.opencontainers.image.title={{.ProjectName}}" -# - "--label=org.opencontainers.image.revision={{.FullCommit}}" -# - "--label=org.opencontainers.image.version={{.Version}}" -# - '--label=org.opencontainers.image.source={{replace (replace (replace .GitURL "git@" "https://") ".git" "") "github.com:" "github.com/"}}' -# - use: buildx -# goos: linux -# goarch: arm -# goarm: "7" -# dockerfile: Dockerfile -# image_templates: -# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm32v7 -# build_flag_templates: -# - "--platform=linux/arm/v7" -# - "--target=goreleaser" -# - "--pull" -# - "--label=org.opencontainers.image.created={{.Date}}" -# - "--label=org.opencontainers.image.title={{.ProjectName}}" -# - "--label=org.opencontainers.image.revision={{.FullCommit}}" -# - "--label=org.opencontainers.image.version={{.Version}}" -# - '--label=org.opencontainers.image.source={{replace (replace (replace .GitURL "git@" "https://") ".git" "") "github.com:" "github.com/"}}' -# docker_manifests: -# - use: docker -# name_template: ghcr.io/ekristen/aws-nuke:v{{ .Version }} -# image_templates: -# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-amd64 -# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm64 -# - ghcr.io/ekristen/aws-nuke:v{{ .Version }}-arm32v7 -# signs: -# - ids: -# - default -# cmd: cosign -# signature: "${artifact}.sig" -# certificate: "${artifact}.pem" -# args: ["sign-blob", "--yes", "--oidc-provider=github", "--oidc-issuer=https://token.actions.githubusercontent.com", "--output-certificate=${certificate}", "--output-signature=${signature}", "${artifact}"] -# artifacts: all -# docker_signs: -# - ids: -# - default -# artifacts: all -# cmd: cosign -# args: ["sign", "--yes", "--oidc-provider=github", "--oidc-issuer=https://token.actions.githubusercontent.com", "--output-certificate=${certificate}", "--output-signature=${signature}", "${artifact}"] -# checksum: -# name_template: "checksums.txt" -# snapshot: -# name_template: '{{ trimprefix .Summary "v" }}' -# changelog: -# disable: true