This repository has been archived by the owner on Jul 30, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
99 lines (96 loc) · 4.03 KB
/
continuous-integration.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
name: Continuous Integration (CI)
on: pull_request
env:
# Forcing Earthly to use colours, to make reading output easier.
FORCE_COLOR: 1
jobs:
go-formatting:
name: Go Formatting
runs-on: ubuntu-latest
steps:
- name: Download Earthly v0.7.17.
run: "sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/download/v0.7.17/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly'"
- name: Checkout code.
uses: actions/checkout@v3
- name: Check Go formatting.
run: earthly --ci +check-go-formatting
shell-formatting:
name: Shell Formatting
runs-on: ubuntu-latest
steps:
- name: Download Earthly v0.7.17.
run: "sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/download/v0.7.17/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly'"
- name: Checkout code.
uses: actions/checkout@v3
- name: Check Shell formatting.
run: earthly --ci +check-shell-formatting
yaml-formatting:
name: YAML Formatting
runs-on: ubuntu-latest
steps:
- name: Download Earthly v0.7.17.
run: "sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/download/v0.7.17/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly'"
- name: Checkout code.
uses: actions/checkout@v3
- name: Check YAML formatting.
run: earthly --ci +check-yaml-formatting
go-linting:
name: Go Linting
runs-on: ubuntu-latest
steps:
- name: Download Earthly v0.7.17.
run: "sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/download/v0.7.17/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly'"
- name: Checkout code.
uses: actions/checkout@v3
- name: Check Go linting.
run: earthly --ci +check-go-linting
shell-linting:
name: Shell Linting
runs-on: ubuntu-latest
steps:
- name: Download Earthly v0.7.17.
run: "sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/download/v0.7.17/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly'"
- name: Checkout code.
uses: actions/checkout@v3
- name: Check Shell linting.
run: earthly --ci +check-shell-linting
modules:
name: Modules
runs-on: ubuntu-latest
steps:
- name: Download Earthly v0.7.17.
run: "sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/download/v0.7.17/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly'"
- name: Checkout code.
uses: actions/checkout@v3
- name: Check modules.
run: earthly --ci +check-modules
compile-darwin-amd64:
name: Compile Darwin AMD64
runs-on: ubuntu-latest
steps:
- name: Download Earthly v0.7.17.
run: "sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/download/v0.7.17/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly'"
- name: Checkout code.
uses: actions/checkout@v3
- name: Compile Darwin AMD64.
run: earthly --ci +compile-darwin-amd64
compile-linux-amd64:
name: Compile Linux AMD64
runs-on: ubuntu-latest
steps:
- name: Download Earthly v0.7.17.
run: "sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/download/v0.7.17/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly'"
- name: Checkout code.
uses: actions/checkout@v3
- name: Compile Linux AMD64.
run: earthly --ci +compile-linux-amd64
unit-test:
name: Unit Test
runs-on: ubuntu-latest
steps:
- name: Download Earthly v0.7.17.
run: "sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/download/v0.7.17/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly'"
- name: Checkout code.
uses: actions/checkout@v3
- name: Unit test.
run: earthly --ci +unit-test