Refactor Gitea workflow to simplify package publishing by replacing manual zip and upload steps with a dedicated publish script.
This commit is contained in:
@@ -18,16 +18,7 @@ jobs:
|
||||
with:
|
||||
go-version: '1.25.4'
|
||||
|
||||
- name: Archive module
|
||||
run: |
|
||||
# Create a zip of the module source excluding unnecessary files
|
||||
zip -r module.zip . -x ".git/*" ".gitea/*" "bin/*" "data/*" "tests/*" "*.zip" "*.db*" "*.hash" "*.out"
|
||||
|
||||
- name: Upload to Gitea Package Registry
|
||||
run: |
|
||||
# Use GREG_TOKEN for authentication as requested
|
||||
# Owner is Quad4-Software based on module path
|
||||
curl --user "Quad4-Software:${{ secrets.GREG_TOKEN }}" \
|
||||
--upload-file module.zip \
|
||||
"https://git.quad4.io/api/packages/Quad4-Software/go/upload"
|
||||
|
||||
- name: Publish Package
|
||||
env:
|
||||
GREG_TOKEN: ${{ secrets.GREG_TOKEN }}
|
||||
run: ./scripts/publish.sh
|
||||
|
||||
Reference in New Issue
Block a user