Skip to content
Snippets Groups Projects
Commit 5c8bb181 authored by Philipp Stadler's avatar Philipp Stadler
Browse files

chore: omit zip from build

Try to reduce artifact size by excluding zip archive from releases.
parent 366688bc
No related branches found
No related tags found
1 merge request!126chore: omit zip from build and add new content
Pipeline #12620 passed
...@@ -26,15 +26,14 @@ build: ...@@ -26,15 +26,14 @@ build:
script: script:
- NPM_VERSION=$(grep '"version":' package.json -m 1 | cut -d '"' -f 4) - NPM_VERSION=$(grep '"version":' package.json -m 1 | cut -d '"' -f 4)
- RELEASE_DIR=sinologie-anki-pack-$NPM_VERSION - RELEASE_DIR=sinologie-anki-pack-$NPM_VERSION
- ZIP="$RELEASE_DIR.zip" - DIR_DOWNLOAD_URL="https://gitlab.phaidra.org/kartenaale/sinologie-anki-pack/-/jobs/$CI_JOB_ID/artifacts/raw/$RELEASE_DIR"
- ZIP_DOWNLOAD_URL="https://gitlab.phaidra.org/kartenaale/sinologie-anki-pack/-/jobs/$CI_JOB_ID/artifacts/raw/$ZIP"
# just to be safe. because the rule does not track folder renamings # just to be safe. because the rule does not track folder renamings
- rm -f apkgs.d.mk - rm -f apkgs.d.mk
- BUILD_PREFIX="" make check ANNOUNCEMENT $ZIP - BUILD_PREFIX="" make check ANNOUNCEMENT $RELEASE_DIR
- echo BUILD_JOB_ID=$CI_JOB_ID > build.env - echo BUILD_JOB_ID=$CI_JOB_ID > build.env
- echo NPM_VERSION=$NPM_VERSION >> build.env - echo NPM_VERSION=$NPM_VERSION >> build.env
- echo RELEASE_DIR=$RELEASE_DIR >> build.env - echo RELEASE_DIR=$RELEASE_DIR >> build.env
- echo ZIP_DOWNLOAD_URL=$ZIP_DOWNLOAD_URL >> build.env - echo DIR_DOWNLOAD_URL=$DIR_DOWNLOAD_URL >> build.env
artifacts: artifacts:
paths: paths:
- sinologie-anki-pack-* - sinologie-anki-pack-*
...@@ -102,8 +101,8 @@ create-gitlab-release: ...@@ -102,8 +101,8 @@ create-gitlab-release:
description: CHANGELOG-$NPM_VERSION.md description: CHANGELOG-$NPM_VERSION.md
assets: assets:
links: links:
- name: "sinologie-anki-pack-$NPM_VERSION.zip" - name: "sinologie-anki-pack-$NPM_VERSION"
url: '$ZIP_DOWNLOAD_URL' url: '$DIR_DOWNLOAD_URL'
whatsapp-ping: whatsapp-ping:
stage: notify stage: notify
......
...@@ -8,7 +8,10 @@ MOSTLY_CLEAN += $(RELEASE_ZIP) ...@@ -8,7 +8,10 @@ MOSTLY_CLEAN += $(RELEASE_ZIP)
MOSTLY_CLEAN_DIRS += $(RELEASE_DIR) MOSTLY_CLEAN_DIRS += $(RELEASE_DIR)
.PHONY: release .PHONY: release
release: $(RELEASE_ZIP) release: $(RELEASE_DIR)
.PHONY: release-zip
release-zip: $(RELEASE_ZIP)
$(RELEASE_DIR): \ $(RELEASE_DIR): \
$(DOCS_HTML) \ $(DOCS_HTML) \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment