Disable Autobuild and setup manual Go build in CodeQL workflow

The Github actions autobuild functionality has been commented out and replaced with manual building using Go. This customized build command ensures better flexibility and control over the build process.
This commit is contained in:
Winni Neessen 2024-03-17 19:19:38 +01:00
parent 7ebaf2d2b7
commit 2af31dcb48
Signed by: wneessen
GPG key ID: 5F3AF39B820C119D

View file

@ -71,8 +71,8 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v3
# - name: Autobuild
# uses: github/codeql-action/autobuild@v3
# Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
@ -80,9 +80,9 @@ jobs:
# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
# - run: |
# echo "Run, Build Application using script"
# ./location_of_script_within_repo/buildscript.sh
- run: |
echo "Run, Build Application using script"
go build -ldflags '-s -w' -o apg github.com/wneessen/apg-go/cmd/apg
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3