.forgejo: make tarball generation manual

This commit is contained in:
Antoine Martin 2024-08-11 23:49:15 -04:00
parent 732ba1c738
commit d9c129fe8f
Signed by: forge
GPG key ID: D62A472A4AA7D541

View file

@ -1,7 +1,10 @@
on:
push:
branches:
- 'refs/tags/*'
workflow_dispatch:
inputs:
ref_name:
description: 'Tag or commit'
required: true
type: string
jobs:
build-tarball:
@ -17,15 +20,15 @@ jobs:
uses: actions/checkout@v4
with:
fetch-depth: 500
ref: ${{ github.ref_name }}
ref: ${{ inputs.ref_name }}
- name: Package build
run: |
echo "building tarball for ${{ githug.ref_name }}"
git-archive-all --force-submodules $CI_PROJECT_NAME-${{ github.ref_name }}.tar.gz
echo "building tarball for ${{ inputs.ref_name }}"
git-archive-all --force-submodules $CI_PROJECT_NAME-${{ inputs.ref_name }}.tar.gz
echo "Generating sha512sum"
sha512sum $CI_PROJECT_NAME-${{ github.ref_name }}.tar.gz > $CI_PROJECT_NAME-${{ github.ref_name }}.tar.gz.sha512sum
sha512sum $CI_PROJECT_NAME-${{ inputs.ref_name }}.tar.gz > $CI_PROJECT_NAME-${{ inputs.ref_name }}.tar.gz.sha512sum
- name: Package upload
uses: forgejo/upload-artifact@v3
with:
name: tarball
path: $CI_PROJECT_NAME-${{ github.ref_name }}.*
path: $CI_PROJECT_NAME-${{ inputs.ref_name }}.*