#2-1: 9bd3e2c595da9de86d8ebea936b690d8d4121edd by OLeonardoRodrigues #2
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 Publish" | |
run-name: "#${{ github.run_number }}-${{ github.run_attempt }}: ${{ github.sha }} by ${{ github.triggering_actor }}" | |
defaults: | |
run: | |
shell: bash | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
name: "Build Application Binary" | |
steps: | |
- name: "Checkout Code: REF ${{github.ref}}" | |
uses: actions/checkout@v4 | |
id: checkout | |
with: | |
ref: ${{github.ref}} | |
persist-credentials : true | |
fetch-depth: 1 | |
fetch-tags: false | |
clean: true | |
- name: "Setup Go Environment" | |
uses: actions/setup-go@v5.1.0 | |
id: setup_go | |
with: | |
go-version-file: "./go.mod" | |
cache: true | |
cache-dependency-path: "./go.sum" | |
- name: "Run Build for ${{ runner.os }} ${{ runner.arch }}" | |
id: build | |
run: make build | |
- name: "Upload Build Artifact" | |
uses: actions/upload-artifact@v4.4.3 | |
id: upload_artifact | |
with: | |
name: "${{ github.run_number }}-${{ github.run_attempt }}-${{ github.sha }}-${{ runner.os }}-${{ runner.arch }}" | |
path: "./dist/discordscaffolder" | |
if-no-files-found: "error" | |
retention-days: 7 | |
compression-level: 9 | |
overwrite: true | |
include-hidden-files: false | |