Skip to content

Commit c7897ac

Browse files
committed
update bool param
1 parent 5ef59c0 commit c7897ac

File tree

1 file changed

+6
-11
lines changed

1 file changed

+6
-11
lines changed

.github/workflows/build.yml

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -14,27 +14,22 @@ on:
1414
- 'macos-15'
1515
Binary:
1616
description: 'Build binary'
17-
required: true
1817
default: false
1918
type: boolean
2019
Golangci:
2120
description: 'Golangci linter check'
22-
required: true
2321
default: true
2422
type: boolean
2523
Gocritic:
2624
description: 'Critic linter check'
27-
required: true
2825
default: true
2926
type: boolean
3027
Gosec:
3128
description: 'Security linter check'
32-
required: true
3329
default: true
3430
type: boolean
3531
TMUX:
3632
description: 'Interface testing'
37-
required: true
3833
default: true
3934
type: boolean
4035
Timeout:
@@ -70,19 +65,19 @@ jobs:
7065
go build -v ./...
7166
7267
- name: Golangci linter check
73-
if: ${{ github.event.inputs.Golangci }}
68+
if: ${{ github.event.inputs.Golangci == 'true' }}
7469
run: |
7570
go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
7671
golangci-lint run ./...
7772
7873
- name: Critic linter check
79-
if: ${{ github.event.inputs.Gocritic }}
74+
if: ${{ github.event.inputs.Gocritic == 'true' }}
8075
run: |
8176
go install github.com/go-critic/go-critic/cmd/gocritic@latest
8277
gocritic check -enableAll ./...
8378
8479
- name: Security linter check
85-
if: ${{ github.event.inputs.Gosec }}
80+
if: ${{ github.event.inputs.Gosec == 'true' }}
8681
run: |
8782
go install github.com/securego/gosec/v2/cmd/gosec@latest
8883
gosec -severity=high ./...
@@ -96,14 +91,14 @@ jobs:
9691
run: docker run -d --name pinguem -p 8085:8085 -p 3005:3005 lifailon/pinguem:latest
9792

9893
- name: Interface testing
99-
if: ${{ github.event.inputs.TMUX }}
94+
if: ${{ github.event.inputs.TMUX == 'true' }}
10095
run: |
10196
tmux -V
10297
chmod +x test.sh
10398
bash test.sh ${{ github.event.inputs.Timeout }} true
10499
105100
- name: Build binaries
106-
if: ${{ github.event.inputs.Binary }}
101+
if: ${{ github.event.inputs.Binary == 'true' }}
107102
run: |
108103
version=$(cat main.go | grep Version: | awk -F '"' '{print $4}')
109104
echo "Get version from main.go: $version"
@@ -120,7 +115,7 @@ jobs:
120115
echo "ARTIFACT_NAME=lazyjournal-$(date +'%d.%m.%Y')" >> $GITHUB_ENV
121116
122117
- name: Upload binaries
123-
if: ${{ github.event.inputs.Binary }}
118+
if: ${{ github.event.inputs.Binary == 'true' }}
124119
uses: actions/upload-artifact@v4
125120
with:
126121
name: ${{ env.ARTIFACT_NAME }}

0 commit comments

Comments
 (0)