Skip to content

Commit fcc4b97

Browse files
chore(ci): daily ci for branches (#2208)
1 parent f0ff282 commit fcc4b97

14 files changed

Lines changed: 137 additions & 0 deletions

.github/workflows/ci_codegen.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ on:
77
description: "The dafny version to run"
88
required: true
99
type: string
10+
branch:
11+
description: "Branch to checkout"
12+
required: false
13+
default: main
14+
type: string
1015

1116
jobs:
1217
code-generation:
@@ -37,6 +42,7 @@ jobs:
3742
3843
- uses: actions/checkout@v6
3944
with:
45+
ref: ${{ inputs.branch }}
4046
submodules: recursive
4147
- run: git submodule update --init --recursive submodules/smithy-dafny
4248

.github/workflows/ci_examples_java.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ on:
88
description: "The Dafny version to run"
99
required: true
1010
type: string
11+
branch:
12+
description: "Branch to checkout"
13+
required: false
14+
default: main
15+
type: string
1116
regenerate-code:
1217
description: "Regenerate code using smithy-dafny"
1318
required: false
@@ -48,6 +53,7 @@ jobs:
4853

4954
- uses: actions/checkout@v6
5055
with:
56+
ref: ${{ inputs.branch }}
5157
submodules: recursive
5258

5359
- name: Setup Java 8

.github/workflows/ci_examples_net.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ on:
88
description: "The Dafny version to run"
99
required: true
1010
type: string
11+
branch:
12+
description: "Branch to checkout"
13+
required: false
14+
default: main
15+
type: string
1116
regenerate-code:
1217
description: "Regenerate code using smithy-dafny"
1318
required: false
@@ -38,6 +43,7 @@ jobs:
3843
steps:
3944
- uses: actions/checkout@v6
4045
with:
46+
ref: ${{ inputs.branch }}
4147
submodules: recursive
4248

4349
- name: Setup .NET Core SDK ${{ matrix.dotnet-version }}

.github/workflows/ci_test_java.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ on:
88
description: "The Dafny version to run"
99
required: true
1010
type: string
11+
branch:
12+
description: "Branch to checkout"
13+
required: false
14+
default: main
15+
type: string
1116
regenerate-code:
1217
description: "Regenerate code using smithy-dafny"
1318
required: false
@@ -49,6 +54,7 @@ jobs:
4954

5055
- uses: actions/checkout@v6
5156
with:
57+
ref: ${{ inputs.branch }}
5258
submodules: recursive
5359

5460
- name: Setup Dafny

.github/workflows/ci_test_net.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ on:
88
description: "The Dafny version to run"
99
required: true
1010
type: string
11+
branch:
12+
description: "Branch to checkout"
13+
required: false
14+
default: main
15+
type: string
1116
regenerate-code:
1217
description: "Regenerate code using smithy-dafny"
1318
required: false
@@ -39,6 +44,7 @@ jobs:
3944
git config --global core.longpaths true
4045
- uses: actions/checkout@v6
4146
with:
47+
ref: ${{ inputs.branch }}
4248
submodules: recursive
4349

4450
- name: Setup .NET Core SDK ${{ matrix.dotnet-version }}

.github/workflows/ci_test_vector_java.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ on:
88
description: "The Dafny version to run"
99
required: true
1010
type: string
11+
branch:
12+
description: "Branch to checkout"
13+
required: false
14+
default: main
15+
type: string
1116
regenerate-code:
1217
description: "Regenerate code using smithy-dafny"
1318
required: false
@@ -60,6 +65,7 @@ jobs:
6065

6166
- uses: actions/checkout@v6
6267
with:
68+
ref: ${{ inputs.branch }}
6369
submodules: recursive
6470

6571
- name: Setup Dafny

.github/workflows/ci_test_vector_net.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ on:
88
description: "The Dafny version to run"
99
required: true
1010
type: string
11+
branch:
12+
description: "Branch to checkout"
13+
required: false
14+
default: main
15+
type: string
1116
regenerate-code:
1217
description: "Regenerate code using smithy-dafny"
1318
required: false
@@ -55,6 +60,7 @@ jobs:
5560

5661
- uses: actions/checkout@v6
5762
with:
63+
ref: ${{ inputs.branch }}
5864
submodules: recursive
5965

6066
- name: Setup Dafny

.github/workflows/dafny_verify_version.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ name: Dafny Verify Version
55

66
on:
77
workflow_call:
8+
inputs:
9+
branch:
10+
description: "Branch to checkout"
11+
required: false
12+
default: main
13+
type: string
814
outputs:
915
version:
1016
description: "The dafny version for verify"
@@ -21,6 +27,8 @@ jobs:
2127
version: ${{ steps.read_property.outputs.dafnyVerifyVersion }}
2228
steps:
2329
- uses: actions/checkout@v6
30+
with:
31+
ref: ${{ inputs.branch }}
2432
- name: Read version from Properties-file
2533
id: read_property
2634
uses: christian-draeger/read-properties@1.1.1

.github/workflows/dafny_version.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ name: Dafny Version
55

66
on:
77
workflow_call:
8+
inputs:
9+
branch:
10+
description: "Branch to checkout"
11+
required: false
12+
default: main
13+
type: string
814
outputs:
915
version:
1016
description: "The dafny version"
@@ -21,6 +27,8 @@ jobs:
2127
version: ${{ steps.read_property.outputs.dafnyVersion }}
2228
steps:
2329
- uses: actions/checkout@v6
30+
with:
31+
ref: ${{ inputs.branch }}
2432
- name: Read version from Properties-file
2533
id: read_property
2634
uses: christian-draeger/read-properties@1.1.1

.github/workflows/daily_ci.yml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,116 +19,170 @@ jobs:
1919
id-token: write
2020
# Don't run the cron builds on forks
2121
if: github.event_name != 'schedule' || github.repository_owner == 'aws'
22+
strategy:
23+
matrix:
24+
branch: [main, v3.x-Java]
2225
uses: ./.github/workflows/dafny_version.yml
26+
with:
27+
branch: ${{ matrix.branch }}
2328
getVerifyVersion:
2429
permissions:
2530
contents: read
2631
pull-requests: write
2732
id-token: write
2833
if: github.event_name != 'schedule' || github.repository_owner == 'aws'
34+
strategy:
35+
matrix:
36+
branch: [main, v3.x-Java]
2937
uses: ./.github/workflows/dafny_verify_version.yml
38+
with:
39+
branch: ${{ matrix.branch }}
3040
daily-ci-format:
3141
permissions:
3242
contents: read
3343
pull-requests: write
3444
id-token: write
3545
needs: getVersion
3646
if: github.event_name != 'schedule' || github.repository_owner == 'aws'
47+
strategy:
48+
matrix:
49+
branch: [main, v3.x-Java]
3750
uses: ./.github/workflows/library_format.yml
3851
with:
3952
dafny: ${{needs.getVersion.outputs.version}}
53+
branch: ${{ matrix.branch }}
4054
daily-ci-codegen:
4155
permissions:
4256
contents: read
4357
pull-requests: write
4458
id-token: write
4559
needs: getVersion
4660
if: github.event_name != 'schedule' || github.repository_owner == 'aws'
61+
strategy:
62+
matrix:
63+
branch: [main, v3.x-Java]
4764
uses: ./.github/workflows/ci_codegen.yml
4865
with:
4966
dafny: ${{needs.getVersion.outputs.version}}
67+
branch: ${{ matrix.branch }}
5068
daily-ci-verification:
5169
permissions:
5270
contents: read
5371
pull-requests: write
5472
id-token: write
5573
needs: getVerifyVersion
5674
if: github.event_name != 'schedule' || github.repository_owner == 'aws'
75+
strategy:
76+
matrix:
77+
branch: [main, v3.x-Java]
5778
uses: ./.github/workflows/library_dafny_verification.yml
5879
with:
5980
dafny: ${{needs.getVerifyVersion.outputs.version}}
81+
branch: ${{ matrix.branch }}
6082
daily-ci-test-vector-verification:
6183
permissions:
6284
contents: read
6385
pull-requests: write
6486
id-token: write
6587
needs: getVerifyVersion
88+
strategy:
89+
matrix:
90+
branch: [main, v3.x-Java]
6691
uses: ./.github/workflows/test_vector_verification.yml
6792
with:
6893
dafny: ${{needs.getVerifyVersion.outputs.version}}
94+
branch: ${{ matrix.branch }}
6995
daily-ci-java:
7096
permissions:
7197
contents: read
7298
pull-requests: write
7399
id-token: write
74100
needs: getVersion
101+
strategy:
102+
matrix:
103+
branch: [main, v3.x-Java]
75104
uses: ./.github/workflows/ci_test_java.yml
76105
with:
77106
dafny: ${{needs.getVersion.outputs.version}}
107+
branch: ${{ matrix.branch }}
78108
daily-ci-java-test-vectors:
79109
permissions:
80110
contents: read
81111
pull-requests: write
82112
id-token: write
83113
needs: getVersion
114+
strategy:
115+
matrix:
116+
branch: [main, v3.x-Java]
84117
uses: ./.github/workflows/ci_test_vector_java.yml
85118
with:
86119
dafny: ${{needs.getVersion.outputs.version}}
120+
branch: ${{ matrix.branch }}
87121
daily-ci-java-examples:
88122
permissions:
89123
contents: read
90124
pull-requests: write
91125
id-token: write
92126
needs: getVersion
127+
strategy:
128+
matrix:
129+
branch: [main, v3.x-Java]
93130
uses: ./.github/workflows/ci_examples_java.yml
94131
with:
95132
dafny: ${{needs.getVersion.outputs.version}}
133+
branch: ${{ matrix.branch }}
96134
daily-ci-net:
97135
permissions:
98136
contents: read
99137
pull-requests: write
100138
id-token: write
101139
needs: getVersion
140+
strategy:
141+
matrix:
142+
branch: [main, v3.x-Java]
102143
uses: ./.github/workflows/ci_test_net.yml
103144
with:
104145
dafny: ${{needs.getVersion.outputs.version}}
146+
branch: ${{ matrix.branch }}
105147
daily-ci-rust:
106148
permissions:
107149
contents: read
108150
pull-requests: write
109151
id-token: write
110152
needs: getVersion
153+
strategy:
154+
matrix:
155+
branch: [main, v3.x-Java]
111156
uses: ./.github/workflows/library_rust_tests.yml
112157
with:
113158
dafny: ${{needs.getVersion.outputs.version}}
159+
branch: ${{ matrix.branch }}
114160
daily-ci-net-test-vectors:
115161
permissions:
116162
contents: read
117163
pull-requests: write
118164
id-token: write
119165
needs: getVersion
166+
strategy:
167+
matrix:
168+
branch: [main, v3.x-Java]
120169
uses: ./.github/workflows/ci_test_vector_net.yml
121170
with:
122171
dafny: ${{needs.getVersion.outputs.version}}
172+
branch: ${{ matrix.branch }}
123173
daily-ci-net-examples:
124174
permissions:
125175
contents: read
126176
pull-requests: write
127177
id-token: write
128178
needs: getVersion
179+
strategy:
180+
matrix:
181+
branch: [main, v3.x-Java]
129182
uses: ./.github/workflows/ci_examples_net.yml
130183
with:
131184
dafny: ${{needs.getVersion.outputs.version}}
185+
branch: ${{ matrix.branch }}
132186
notify:
133187
permissions:
134188
contents: read

0 commit comments

Comments
 (0)