Skip to content

Commit b6897ef

Browse files
authored
Merge pull request #3 from ComplianceAsCode/add_ci
Add CI
2 parents ab346da + 0cdf6c4 commit b6897ef

File tree

2 files changed

+59
-0
lines changed

2 files changed

+59
-0
lines changed

.github/workflows/main.yaml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
---
2+
name: CI
3+
4+
on:
5+
push:
6+
branches:
7+
- main
8+
pull_request:
9+
branches:
10+
- main
11+
12+
concurrency:
13+
group: ${{ github.workflow }}-ci-${{ github.event.number || github.run_id }}
14+
cancel-in-progress: true
15+
16+
jobs:
17+
tests:
18+
name: Tests
19+
runs-on: ubuntu-latest
20+
strategy:
21+
fail-fast: false
22+
matrix:
23+
go:
24+
- 'stable'
25+
- 'oldstable'
26+
container: quay.io/projectquay/golang:1.23
27+
steps:
28+
- name: Checkout
29+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
30+
- name: Setup Go
31+
uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
32+
with:
33+
go-version: ${{ matrix.go }}
34+
- name: Test
35+
run: go test ./...
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Merge Commit Check
2+
3+
on:
4+
pull_request:
5+
6+
concurrency:
7+
group: ${{ github.workflow }}-no-merges-${{ github.event.number || github.run_id }}
8+
cancel-in-progress: true
9+
10+
permissions:
11+
contents: read
12+
pull-requests: read
13+
14+
jobs:
15+
validate-merge-commits:
16+
name: Ensure No Merge Commits
17+
runs-on: ubuntu-latest
18+
steps:
19+
- name: Checkout
20+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
21+
- name: Check for Merge Commits
22+
uses: NexusPHP/no-merge-commits@8c8c0fc273903ab75038323e3959179e89db480b # v2.2.1
23+
with:
24+
token: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)