-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor the code #16
Changes from all commits
7b46b4b
3cbcb95
de7692a
ada7a38
516c339
98811f5
60e00c0
304f45a
368b500
a9ab138
f69cdf8
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,38 @@ | ||
name: Linux Build | ||
|
||
on: | ||
workflow_dispatch: # Enable manual execution | ||
workflow_dispatch: # Allow manual execution | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
# Checkout the repository | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
# Set up Go | ||
- name: Set up Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: 1.23 | ||
|
||
# Install dependencies and run the tests | ||
- name: Install Dependencies | ||
run: | | ||
sudo apt-get install -y make | ||
make format | ||
make test | ||
continue-on-error: false | ||
|
||
# Build the application | ||
- name: Build for Linux | ||
run: | | ||
make build | ||
continue-on-error: false | ||
|
||
# Debug: List Build Directory | ||
- name: List Build Directory | ||
run: ls -R bin | ||
|
||
# Upload Build Artifact | ||
- name: Upload Build Artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: gogg-linux-amd64 | ||
path: 'bin/gogg' | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: 1.23 | ||
|
||
- name: Install Dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y make | ||
make test | ||
continue-on-error: false | ||
|
||
- name: Build for Linux | ||
run: | | ||
make build | ||
continue-on-error: false | ||
|
||
- name: List Build Directory (for Debugging) | ||
run: ls -R bin | ||
|
||
- name: Upload Build Artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: gogg-linux-amd64 | ||
path: 'bin/gogg' | ||
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,37 @@ | ||
name: MacOS Build | ||
|
||
on: | ||
workflow_dispatch: # Enable manual execution | ||
workflow_dispatch: # Allow manual execution | ||
|
||
jobs: | ||
build: | ||
runs-on: macos-latest | ||
|
||
steps: | ||
# Checkout the repository | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
# Set up Go | ||
- name: Set up Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: 1.23 | ||
|
||
# Install dependencies and run the tests | ||
- name: Install Dependencies | ||
run: | | ||
brew install make | ||
make format | ||
make test | ||
continue-on-error: false | ||
|
||
# Build the application | ||
- name: Build for MacOS | ||
run: | | ||
make build-macos | ||
continue-on-error: false | ||
|
||
# Debug: List Build Directory | ||
- name: List Build Directory | ||
run: ls -R bin | ||
|
||
# Upload Build Artifact | ||
- name: Upload Build Artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: gogg-macos-universal | ||
path: 'bin/gogg' | ||
build: | ||
runs-on: macos-latest | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: 1.23 | ||
|
||
- name: Install Dependencies | ||
run: | | ||
brew install make | ||
make test | ||
continue-on-error: false | ||
|
||
- name: Build for MacOS | ||
run: | | ||
make build-macos | ||
continue-on-error: false | ||
|
||
- name: List Build Directory (for Debugging) | ||
run: ls -R bin | ||
|
||
- name: Upload Build Artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: gogg-macos-universal | ||
path: 'bin/gogg' | ||
Comment on lines
+8
to
+37
Check warning Code scanning / CodeQL Workflow does not contain permissions Medium
Actions Job or Workflow does not set permissions
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,37 @@ | ||
name: Windows Build | ||
|
||
on: | ||
workflow_dispatch: # Enable manual execution | ||
workflow_dispatch: # Allow manual execution | ||
|
||
jobs: | ||
build: | ||
runs-on: windows-latest | ||
|
||
steps: | ||
# Checkout the repository | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
# Set up Go | ||
- name: Set up Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: 1.23 | ||
|
||
# Install dependencies and run the tests | ||
- name: Install Dependencies | ||
run: | | ||
choco install make -y | ||
make format | ||
make test | ||
continue-on-error: false | ||
|
||
# Build the application | ||
- name: Build for Windows | ||
run: | | ||
make build GOGG_BINARY=gogg.exe | ||
continue-on-error: false | ||
|
||
# Debug: List Build Directory | ||
- name: List Build Directory | ||
run: ls -R bin | ||
|
||
# Upload Build Artifact | ||
- name: Upload Build Artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: gogg-windows-amd64 | ||
path: 'bin/gogg.exe' | ||
build: | ||
runs-on: windows-latest | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: 1.23 | ||
|
||
- name: Install Dependencies | ||
run: | | ||
choco install make -y | ||
make test | ||
continue-on-error: false | ||
|
||
- name: Build for Windows | ||
run: | | ||
make build GOGG_BINARY=gogg.exe | ||
continue-on-error: false | ||
|
||
- name: List Build Directory (for Debugging) | ||
run: ls -R bin | ||
|
||
- name: Upload Build Artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: gogg-windows-amd64 | ||
path: 'bin/gogg.exe' | ||
Comment on lines
+8
to
+37
Check warning Code scanning / CodeQL Workflow does not contain permissions Medium
Actions Job or Workflow does not set permissions
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,31 @@ | ||
name: Run Linters | ||
|
||
on: | ||
workflow_dispatch: # Allow manual execution | ||
push: | ||
tags: | ||
- 'v*' # Trigger on version tags | ||
workflow_dispatch: # Allow manual execution | ||
push: | ||
tags: | ||
- 'v*' # Trigger on version tags | ||
|
||
jobs: | ||
lint: | ||
runs-on: ubuntu-latest | ||
lint: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: '1.23' | ||
- name: Set up Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: 1.23 | ||
|
||
- name: Install golangci-lint | ||
run: | | ||
make install-deps | ||
- name: Install Dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y make | ||
make install-deps | ||
|
||
- name: Run golangci-lint | ||
run: | | ||
make lint | ||
- name: Run Linters | ||
run: | | ||
make lint | ||
continue-on-error: false | ||
Comment on lines
+11
to
+31
Check warning Code scanning / CodeQL Workflow does not contain permissions Medium
Actions Job or Workflow does not set permissions
|
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium