-
Notifications
You must be signed in to change notification settings - Fork 82
187 lines (187 loc) · 8.73 KB
/
nix-action-coq-8.16-ubuntu.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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
jobs:
coq:
needs: []
runs-on: ubuntu-latest
concurrency:
group: ${{ github.workflow }}-Ubuntu-coq-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
steps:
- name: Determine which commit to test
run: "if [ ${{ github.event_name }} = \"push\" ]; then\n echo \"tested_commit=${{\
\ github.sha }}\" >> $GITHUB_ENV\nelse\n merge_commit=$(git ls-remote ${{\
\ github.event.repository.html_url }} refs/pull/${{ github.event.number }}/merge\
\ | cut -f1)\n if [ -z \"$merge_commit\" ]; then\n echo \"tested_commit=${{\
\ github.event.pull_request.head.sha }}\" >> $GITHUB_ENV\n else\n echo\
\ \"tested_commit=$merge_commit\" >> $GITHUB_ENV\n fi\nfi\n"
- name: Git checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ env.tested_commit }}
- name: Cachix install
uses: cachix/install-nix-action@v30
with:
nix_path: nixpkgs=channel:nixpkgs-unstable
- name: Cachix setup metacoq
uses: cachix/cachix-action@v15
with:
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
extraPullNames: coq, coq-community
name: metacoq
- id: stepCheck
name: Checking presence of CI target coq
run: "nb_dry_run=$(NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link \\\n --argstr\
\ bundle \"coq-8.16\" --argstr job \"coq\" \\\n --dry-run 2>&1 > /dev/null)\n\
echo $nb_dry_run\necho ::set-output name=status::$(echo $nb_dry_run | grep\
\ \"built:\" | sed \"s/.*/built/\")\n"
- if: steps.stepCheck.outputs.status == 'built'
name: Building/fetching current CI target
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "coq"
equations:
needs:
- coq
runs-on: ubuntu-latest
concurrency:
group: ${{ github.workflow }}-Ubuntu-equations-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
steps:
- name: Determine which commit to test
run: "if [ ${{ github.event_name }} = \"push\" ]; then\n echo \"tested_commit=${{\
\ github.sha }}\" >> $GITHUB_ENV\nelse\n merge_commit=$(git ls-remote ${{\
\ github.event.repository.html_url }} refs/pull/${{ github.event.number }}/merge\
\ | cut -f1)\n if [ -z \"$merge_commit\" ]; then\n echo \"tested_commit=${{\
\ github.event.pull_request.head.sha }}\" >> $GITHUB_ENV\n else\n echo\
\ \"tested_commit=$merge_commit\" >> $GITHUB_ENV\n fi\nfi\n"
- name: Git checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ env.tested_commit }}
- name: Cachix install
uses: cachix/install-nix-action@v30
with:
nix_path: nixpkgs=channel:nixpkgs-unstable
- name: Cachix setup metacoq
uses: cachix/cachix-action@v15
with:
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
extraPullNames: coq, coq-community
name: metacoq
- id: stepCheck
name: Checking presence of CI target equations
run: "nb_dry_run=$(NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link \\\n --argstr\
\ bundle \"coq-8.16\" --argstr job \"equations\" \\\n --dry-run 2>&1 > /dev/null)\n\
echo $nb_dry_run\necho ::set-output name=status::$(echo $nb_dry_run | grep\
\ \"built:\" | sed \"s/.*/built/\")\n"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: coq'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "coq"
- if: steps.stepCheck.outputs.status == 'built'
name: Building/fetching current CI target
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "equations"
metacoq:
needs:
- coq
- equations
runs-on: ubuntu-latest
concurrency:
group: ${{ github.workflow }}-Ubuntu-metacoq-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
steps:
- name: Determine which commit to test
run: "if [ ${{ github.event_name }} = \"push\" ]; then\n echo \"tested_commit=${{\
\ github.sha }}\" >> $GITHUB_ENV\nelse\n merge_commit=$(git ls-remote ${{\
\ github.event.repository.html_url }} refs/pull/${{ github.event.number }}/merge\
\ | cut -f1)\n if [ -z \"$merge_commit\" ]; then\n echo \"tested_commit=${{\
\ github.event.pull_request.head.sha }}\" >> $GITHUB_ENV\n else\n echo\
\ \"tested_commit=$merge_commit\" >> $GITHUB_ENV\n fi\nfi\n"
- name: Git checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ env.tested_commit }}
- name: Cachix install
uses: cachix/install-nix-action@v30
with:
nix_path: nixpkgs=channel:nixpkgs-unstable
- name: Cachix setup metacoq
uses: cachix/cachix-action@v15
with:
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
extraPullNames: coq, coq-community
name: metacoq
- id: stepCheck
name: Checking presence of CI target metacoq
run: "nb_dry_run=$(NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link \\\n --argstr\
\ bundle \"coq-8.16\" --argstr job \"metacoq\" \\\n --dry-run 2>&1 > /dev/null)\n\
echo $nb_dry_run\necho ::set-output name=status::$(echo $nb_dry_run | grep\
\ \"built:\" | sed \"s/.*/built/\")\n"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: coq'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "coq"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: equations'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "equations"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-utils'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-utils"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-common'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-common"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-template-coq'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-template-coq"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-pcuic'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-pcuic"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-safechecker'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-safechecker"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-template-pcuic'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-template-pcuic"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-erasure'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-erasure"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-quotation'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-quotation"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-safechecker-plugin'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-safechecker-plugin"
- if: steps.stepCheck.outputs.status == 'built'
name: 'Building/fetching previous CI target: metacoq-erasure-plugin'
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq-erasure-plugin"
- if: steps.stepCheck.outputs.status == 'built'
name: Building/fetching current CI target
run: NIXPKGS_ALLOW_UNFREE=1 nix-build --no-out-link --argstr bundle "coq-8.16"
--argstr job "metacoq"
name: Nix CI for bundle coq-8.16
'on':
pull_request:
paths:
- .github/workflows/**
pull_request_target:
types:
- opened
- synchronize
- reopened
push:
branches:
- master
- coq-8.16