Create myexe.yaml #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Upload Windows EXE | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
jobs: | |
build-and-upload: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: '1.22' | |
- name: Build executable | |
run: go build -o myapp.exe ./... | |
# Ensure this command correctly builds your .exe. Adjust as needed. | |
- name: Upload EXE as artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: windows-exe | |
path: myapp.exe |