Skip to content

Commit 1a3d1f0

Browse files
chore(ci): remove branch default to main (#2219)
1 parent d6fd0fb commit 1a3d1f0

13 files changed

Lines changed: 13 additions & 26 deletions

.github/workflows/ci_codegen.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ on:
1010
branch:
1111
description: "Branch to checkout"
1212
required: false
13-
default: main
1413
type: string
1514

1615
jobs:
@@ -42,7 +41,7 @@ jobs:
4241
4342
- uses: actions/checkout@v6
4443
with:
45-
ref: ${{ inputs.branch }}
44+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
4645
submodules: recursive
4746
- run: git submodule update --init --recursive submodules/smithy-dafny
4847

.github/workflows/ci_examples_java.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ on:
1111
branch:
1212
description: "Branch to checkout"
1313
required: false
14-
default: main
1514
type: string
1615
regenerate-code:
1716
description: "Regenerate code using smithy-dafny"
@@ -53,7 +52,7 @@ jobs:
5352

5453
- uses: actions/checkout@v6
5554
with:
56-
ref: ${{ inputs.branch }}
55+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
5756
submodules: recursive
5857

5958
- name: Setup Java 8

.github/workflows/ci_examples_net.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ on:
1111
branch:
1212
description: "Branch to checkout"
1313
required: false
14-
default: main
1514
type: string
1615
regenerate-code:
1716
description: "Regenerate code using smithy-dafny"
@@ -43,7 +42,7 @@ jobs:
4342
steps:
4443
- uses: actions/checkout@v6
4544
with:
46-
ref: ${{ inputs.branch }}
45+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
4746
submodules: recursive
4847

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

.github/workflows/ci_test_java.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ on:
1111
branch:
1212
description: "Branch to checkout"
1313
required: false
14-
default: main
1514
type: string
1615
regenerate-code:
1716
description: "Regenerate code using smithy-dafny"
@@ -54,7 +53,7 @@ jobs:
5453

5554
- uses: actions/checkout@v6
5655
with:
57-
ref: ${{ inputs.branch }}
56+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
5857
submodules: recursive
5958

6059
- name: Setup Dafny

.github/workflows/ci_test_net.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ on:
1111
branch:
1212
description: "Branch to checkout"
1313
required: false
14-
default: main
1514
type: string
1615
regenerate-code:
1716
description: "Regenerate code using smithy-dafny"
@@ -44,7 +43,7 @@ jobs:
4443
git config --global core.longpaths true
4544
- uses: actions/checkout@v6
4645
with:
47-
ref: ${{ inputs.branch }}
46+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
4847
submodules: recursive
4948

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

.github/workflows/ci_test_vector_java.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ on:
1111
branch:
1212
description: "Branch to checkout"
1313
required: false
14-
default: main
1514
type: string
1615
regenerate-code:
1716
description: "Regenerate code using smithy-dafny"
@@ -65,7 +64,7 @@ jobs:
6564

6665
- uses: actions/checkout@v6
6766
with:
68-
ref: ${{ inputs.branch }}
67+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
6968
submodules: recursive
7069

7170
- name: Setup Dafny

.github/workflows/ci_test_vector_net.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ on:
1111
branch:
1212
description: "Branch to checkout"
1313
required: false
14-
default: main
1514
type: string
1615
regenerate-code:
1716
description: "Regenerate code using smithy-dafny"
@@ -60,7 +59,7 @@ jobs:
6059

6160
- uses: actions/checkout@v6
6261
with:
63-
ref: ${{ inputs.branch }}
62+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
6463
submodules: recursive
6564

6665
- name: Setup Dafny

.github/workflows/dafny_verify_version.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ on:
99
branch:
1010
description: "Branch to checkout"
1111
required: false
12-
default: main
1312
type: string
1413
outputs:
1514
version:
@@ -28,7 +27,7 @@ jobs:
2827
steps:
2928
- uses: actions/checkout@v6
3029
with:
31-
ref: ${{ inputs.branch }}
30+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
3231
- name: Read version from Properties-file
3332
id: read_property
3433
uses: christian-draeger/read-properties@1.1.1

.github/workflows/dafny_version.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ on:
99
branch:
1010
description: "Branch to checkout"
1111
required: false
12-
default: main
1312
type: string
1413
outputs:
1514
version:
@@ -28,7 +27,7 @@ jobs:
2827
steps:
2928
- uses: actions/checkout@v6
3029
with:
31-
ref: ${{ inputs.branch }}
30+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
3231
- name: Read version from Properties-file
3332
id: read_property
3433
uses: christian-draeger/read-properties@1.1.1

.github/workflows/library_dafny_verification.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ on:
1111
branch:
1212
description: "Branch to checkout"
1313
required: false
14-
default: main
1514
type: string
1615
regenerate-code:
1716
description: "Regenerate code using smithy-dafny"
@@ -59,7 +58,7 @@ jobs:
5958
steps:
6059
- uses: actions/checkout@v6
6160
with:
62-
ref: ${{ inputs.branch }}
61+
ref: ${{ inputs.branch || github.head_ref || github.ref }}
6362
submodules: recursive
6463

6564
- name: Setup Dafny

0 commit comments

Comments
 (0)