Apply patch in workflow
This commit is contained in:
parent
f2c97e234b
commit
49919707c0
1 changed files with 11 additions and 3 deletions
|
@ -11,17 +11,18 @@ jobs:
|
|||
name: Build tarball w/ submodules
|
||||
runs-on: x86_64
|
||||
container:
|
||||
image: alpine:latest
|
||||
image: alpine:3.19
|
||||
env:
|
||||
CI_PROJECT_NAME: papermc
|
||||
steps:
|
||||
- name: Environment setup
|
||||
run: apk add nodejs git git-archive-all gzip
|
||||
run: apk add nodejs git openjdk21-jre-headless gzip
|
||||
- name: Repo pull
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 500
|
||||
ref: ${{ inputs.ref_name }}
|
||||
path: $CI_PROJECT_NAME
|
||||
- name: Package build
|
||||
run: |
|
||||
if test $GITHUB_REF_NAME == "ci" ; then
|
||||
|
@ -30,7 +31,14 @@ jobs:
|
|||
CI_REF_NAME=$GITHUB_REF_NAME
|
||||
fi
|
||||
echo "building tarball for $CI_REF_NAME"
|
||||
git-archive-all --force-submodules $CI_PROJECT_NAME-$CI_REF_NAME.tar.gz
|
||||
cd $CI_PROJECT_NAME
|
||||
./gradlew --parallel applyPatches
|
||||
cd ../
|
||||
mv $CI_PROJECT_NAME $CI_PROJECT_NAME-$CI_REF_NAME
|
||||
msg "generating tarball.."
|
||||
tar -cf $CI_PROJECT_NAME-$CI_REF_NAME.tar --exclude-backups --exclude-caches-all --exclude-vcs $CI_PROJECT_NAME-$CI_REF_NAME
|
||||
echo "Compressing $CI_PROJECT_NAME-$CI_REF_NAME.tar.xz"
|
||||
xz -T0 -9 -vv -e -c > ./$CI_PROJECT_NAME-$CI_REF_NAME.tar.xz < ./$CI_PROJECT_NAME-$CI_REF_NAME.tar
|
||||
echo "Generating sha512sum"
|
||||
sha512sum $CI_PROJECT_NAME-$CI_REF_NAME.tar.gz > $CI_PROJECT_NAME-$CI_REF_NAME.tar.gz.sha512sum
|
||||
- name: Package upload
|
Loading…
Reference in a new issue