Skip to content

Commit a5026d7

Browse files
author
guylev008
committed
Add a CI to run on branch
1 parent 9b0ae53 commit a5026d7

2 files changed

Lines changed: 70 additions & 1 deletion

File tree

.github/workflows/CI.yml

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
name: CI
2+
3+
# Controls when the workflow will run
4+
on: [push, workflow_dispatch, pull_request]
5+
6+
env:
7+
SPECTRAL_DSN: ${{ secrets.SPECTRAL_DSN }}
8+
9+
jobs:
10+
ubuntu-ci:
11+
name: Spectral ubuntu CI
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v3
15+
- name: Install and run Spectral CI
16+
uses: ./
17+
with:
18+
spectral-dsn: ${{ env.SPECTRAL_DSN }}
19+
spectral-args: scan --ok
20+
ubuntu-audit:
21+
name: Spectral ubuntu audit
22+
runs-on: ubuntu-latest
23+
steps:
24+
- uses: actions/checkout@v3
25+
- name: Install and run Spectral Audit
26+
uses: ./
27+
with:
28+
spectral-dsn: ${{ env.SPECTRAL_DSN }}
29+
spectral-args: github -k repo -t ${{ secrets.MY_GITHUB_TOKEN }} https://github.com/SpectralOps/spectral-github-action --include-tags base,audit --ok
30+
macos-ci:
31+
name: Spectral macos CI
32+
runs-on: ubuntu-latest
33+
steps:
34+
- uses: actions/checkout@v3
35+
- name: Install and run Spectral CI
36+
uses: ./
37+
with:
38+
spectral-dsn: ${{ env.SPECTRAL_DSN }}
39+
spectral-args: scan --ok
40+
macos-audit:
41+
name: Spectral macos audit
42+
runs-on: ubuntu-latest
43+
steps:
44+
- uses: actions/checkout@v3
45+
- name: Install and run Spectral Audit
46+
uses: ./
47+
with:
48+
spectral-dsn: ${{ env.SPECTRAL_DSN }}
49+
spectral-args: github -k repo -t ${{ secrets.MY_GITHUB_TOKEN }} https://github.com/SpectralOps/spectral-github-action --include-tags base,audit --ok
50+
windows-ci:
51+
name: Spectral windows CI
52+
runs-on: windows-latest
53+
steps:
54+
- uses: actions/checkout@v3
55+
- name: Install and run Spectral CI
56+
uses: ./
57+
with:
58+
spectral-dsn: ${{ env.SPECTRAL_DSN }}
59+
spectral-args: scan --ok
60+
windows-audit:
61+
name: Spectral windows audit
62+
runs-on: windows-latest
63+
steps:
64+
- uses: actions/checkout@v3
65+
- name: Install and run Spectral Audit
66+
uses: ./
67+
with:
68+
spectral-dsn: ${{ env.SPECTRAL_DSN }}
69+
spectral-args: github -k repo -t ${{ secrets.MY_GITHUB_TOKEN }} https://github.com/SpectralOps/spectral-github-action --include-tags base,audit --ok

.github/workflows/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: CI
22

33
# Controls when the workflow will run
4-
on: [push, workflow_dispatch, pull_request]
4+
on: [push, workflow_dispatch]
55

66
env:
77
SPECTRAL_DSN: ${{ secrets.SPECTRAL_DSN }}

0 commit comments

Comments
 (0)