Update .gitlab-ci.yml file

This commit is contained in:
WinterMyst 2024-09-23 20:35:44 +00:00
parent 1e1fa46ee0
commit 79ca616ad7

View File

@ -54,14 +54,11 @@ release:
- npm install - npm install
- gulp release - gulp release
# Update system.json with the release URL
- |
sed -i "s|\"download\":.*|\"download\": \"https://gitlab.com/$CI_PROJECT_NAMESPACE/$CI_PROJECT_NAME/-/releases/v$VERSION/download\",|" system.json
- grep '"download":' system.json - grep '"download":' system.json
- git config --global user.name "GitLab CI" - git config --global user.name "GitLab CI"
- git config --global user.email "ci@gitlab.com" - git config --global user.email "ci@gitlab.com"
- git add system.json - git add kidsonbrooms.zip
- git commit -m "Update system.json with release URL" - git commit -m "Update .zip with new version"
- git push "https://$CI_COMMITTER_USER_AND_TOKEN@gitlab.com/${CI_PROJECT_NAMESPACE}/${CI_PROJECT_NAME}.git" HEAD:master - git push "https://$CI_COMMITTER_USER_AND_TOKEN@gitlab.com/${CI_PROJECT_NAMESPACE}/${CI_PROJECT_NAME}.git" HEAD:master
# Create a release on GitLab # Create a release on GitLab
@ -78,7 +75,7 @@ release:
"links": [ "links": [
{ {
"name": "Download kidsonbrooms.zip", "name": "Download kidsonbrooms.zip",
"url": "https://gitlab.com/wintermyst/kidsonbrooms/-/jobs/$CI_JOB_ID/artifacts/download" "url": "https://gitlab.com/wintermyst/kidsonbrooms/-/raw/master/kidsonbrooms.zip?inline=false"
} }
] ]
} }
@ -92,7 +89,7 @@ release:
\"id\": \"Your-Package-ID\", \"id\": \"Your-Package-ID\",
\"release\": { \"release\": {
\"version\": \"$VERSION\", \"version\": \"$VERSION\",
\"manifest\": \"https://gitlab.com/${CI_PROJECT_NAMESPACE}/${CI_PROJECT_NAME}/-/raw/master/system.json\", \"manifest\": \"https://gitlab.com/wintermyst/kidsonbrooms/-/raw/master/system.json",
\"notes\": \"https://gitlab.com/${CI_PROJECT_NAMESPACE}/${CI_PROJECT_NAME}/-/releases/v$VERSION\", \"notes\": \"https://gitlab.com/${CI_PROJECT_NAMESPACE}/${CI_PROJECT_NAME}/-/releases/v$VERSION\",
\"compatibility\": { \"compatibility\": {
\"minimum\": \"12.331\", \"minimum\": \"12.331\",
@ -111,12 +108,3 @@ release:
paths: paths:
- kidsonbrooms.zip - kidsonbrooms.zip
expire_in: never expire_in: never
release:
name: "Release v$VERSION"
tag_name: "v$VERSION"
description: "Release v$VERSION"
ref: master
assets:
links:
- name: "Download kidsonbrooms.zip"
url: "https://gitlab.com/${CI_PROJECT_NAMESPACE}/${CI_PROJECT_NAME}/-/jobs/${CI_JOB_ID}/artifacts/raw/kidsonbrooms.zip"