Skip to content

Commit 81e40f9

Browse files
authored
Merge pull request #172 from per1234/build-task
Add project build task
2 parents 1e02a7f + 23fc189 commit 81e40f9

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

Taskfile.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,11 @@ vars:
3939
)
4040
4141
tasks:
42+
build:
43+
desc: Build the project
44+
deps:
45+
- task: go:build
46+
4247
# Source: https://github.com/arduino/tooling-project-assets/blob/main/workflow-templates/assets/check-workflows-task/Taskfile.yml
4348
ci:validate:
4449
desc: Validate GitHub Actions workflows against their JSON schema
@@ -155,6 +160,16 @@ tasks:
155160
run: when_changed
156161
# No preparation is needed for Go module-based projects.
157162

163+
# Source: https://github.com/arduino/tooling-project-assets/blob/main/workflow-templates/assets/go-task/Taskfile.yml
164+
go:build:
165+
desc: Build the Go code
166+
dir: "{{.DEFAULT_GO_MODULE_PATH}}"
167+
cmds:
168+
- |
169+
go build \
170+
-v \
171+
{{.LDFLAGS}}
172+
158173
# Source: https://github.com/arduino/tooling-project-assets/blob/main/workflow-templates/assets/check-go-task/Taskfile.yml
159174
go:fix:
160175
desc: |

0 commit comments

Comments
 (0)