Skip to content

Commit 5feca81

Browse files
committed
feat: added env support to go-test and go-check workflows
1 parent 5dc3d35 commit 5feca81

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

.github/workflows/go-check.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@ on:
1212
required: false
1313
type: boolean
1414
default: false
15+
env:
16+
required: false
17+
type: string
1518
secrets:
1619
CHECKOUT_TOKEN:
1720
required: false
@@ -21,6 +24,12 @@ jobs:
2124
runs-on: ubuntu-latest
2225
name: All
2326
steps:
27+
- name: Set env
28+
if: ${{ inputs.env }}
29+
env:
30+
ENV: ${{ inputs.env }}
31+
run: |
32+
echo "$ENV" >> $GITHUB_ENV
2433
- name: Check out the repository
2534
uses: actions/checkout@v5
2635
with:

.github/workflows/go-test.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ on:
1010
required: false
1111
type: boolean
1212
default: false
13+
env:
14+
required: false
15+
type: string
1316
secrets:
1417
CODECOV_TOKEN:
1518
required: false
@@ -34,6 +37,12 @@ jobs:
3437
runs-on: ${{ fromJSON(vars[format('UCI_GO_TEST_RUNNER_{0}', matrix.os)] || format('"{0}-latest"', matrix.os)) }}
3538
name: ${{ matrix.os }} (go ${{ matrix.go }})
3639
steps:
40+
- name: Set env
41+
if: ${{ inputs.env }}
42+
env:
43+
ENV: ${{ inputs.env }}
44+
run: |
45+
echo "$ENV" >> $GITHUB_ENV
3746
- name: Use msys2 on windows
3847
if: matrix.os == 'windows'
3948
# The executable for msys2 is also called bash.cmd

CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
66

77
## Unreleased
88
### Added
9-
- `CHECKOUT_TOKEN` support to `go-test` and `go-check` workflows
9+
- `env` input support to `go-test` and `go-check` workflows
10+
- `CHECKOUT_TOKEN` secret support to `go-test` and `go-check` workflows
1011

1112
## [1.0.34] - 2025-09-16
1213
### Fixed

0 commit comments

Comments
 (0)