From 91f13133f3545ef361287cebd9c1875c60bc01b6 Mon Sep 17 00:00:00 2001
From: sarna
Date: Wed, 17 May 2023 12:18:19 -0600
Subject: [PATCH 1/4] Don't run cicd workflow on merge to main
The CI already exercises the workflow on feature branches when user opens a PR.
---
.github/workflows/cicd.yml | 2 --
1 file changed, 2 deletions(-)
diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml
index 65c7898b..9f3ad202 100644
--- a/.github/workflows/cicd.yml
+++ b/.github/workflows/cicd.yml
@@ -2,8 +2,6 @@ name: Continuous Integration
on:
push:
- branches:
- - main
tags:
- 'v[0-9]+.[0-9]+.[0-9]+'
pull_request:
From b508d31b6e363ceb3d064ae6792ae9b156050acb Mon Sep 17 00:00:00 2001
From: sarna
Date: Wed, 17 May 2023 12:21:26 -0600
Subject: [PATCH 2/4] Don't run workflows on tags
The tags are being cut off main which is already tested so this is not needed.
---
.github/workflows/cicd.yml | 3 ---
1 file changed, 3 deletions(-)
diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml
index 9f3ad202..8803205e 100644
--- a/.github/workflows/cicd.yml
+++ b/.github/workflows/cicd.yml
@@ -1,9 +1,6 @@
name: Continuous Integration
on:
- push:
- tags:
- - 'v[0-9]+.[0-9]+.[0-9]+'
pull_request:
branches:
- main
From 7ba5f307eb6cb7b5b59143c402ff0f24d85a5e04 Mon Sep 17 00:00:00 2001
From: sarna
Date: Wed, 17 May 2023 13:33:45 -0600
Subject: [PATCH 3/4] Golang CI lint "only-new-issues" needs perms to read PRs
---
.github/workflows/cicd.yml | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml
index 8803205e..9fd507d0 100644
--- a/.github/workflows/cicd.yml
+++ b/.github/workflows/cicd.yml
@@ -9,6 +9,10 @@ on:
- reopened
- synchronize
+permissions:
+ contents: read
+ pull-requests: read
+
jobs:
checks:
name: Linting
From 7d7b002456dc4103d782b7ab6164092bbcf107a9 Mon Sep 17 00:00:00 2001
From: sarna
Date: Wed, 17 May 2023 13:53:04 -0600
Subject: [PATCH 4/4] drop: test without new issues var
---
.github/workflows/cicd.yml | 2 --
1 file changed, 2 deletions(-)
diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml
index 9fd507d0..1b45ecca 100644
--- a/.github/workflows/cicd.yml
+++ b/.github/workflows/cicd.yml
@@ -26,8 +26,6 @@ jobs:
go-version-file: go.mod
- name: Lint Code
uses: golangci/golangci-lint-action@v3
- with:
- only-new-issues: true
unit-tests:
name: Unit Tests