loglib/.gitlab-ci.yml
Netkas 0311fcf3f0
Remove unused run configuration and update CI pipeline
This commit removes 'Install.xml' run configuration, which is no longer used or necessary in the project. The '.gitlab-ci.yml' file has also been updated to include a new 'prepare' stage in the pipeline. This modification was done to streamline and improve the CI/CD process by explicitly installing necessary project dependencies before the build phase begins.
2023-10-11 17:49:15 -04:00

48 lines
No EOL
1.5 KiB
YAML

image: repo.n64.cc:443/nosial/ncc:latest
stages:
- prepare
- build
- publish
variables:
PACKAGE_NAME: $CI_COMMIT_REF_NAME
prepare:
stage: prepare
script:
- ncc project install
build:
stage: build
script:
- ncc build --config release --log-level debug -o "build/release/net.nosial.loglib.ncc"
artifacts:
paths:
- "build/release/net.nosial.loglib.ncc"
build_static:
stage: build
script:
- ncc build --config release_static --log-level debug -o "build/release/net.nosial.loglib_static.ncc"
artifacts:
paths:
- "build/release/net.nosial.loglib_static.ncc"
publish:
stage: publish
before_script:
- 'if [ "$CI_COMMIT_REF_NAME" == "master" ]; then PACKAGE_NAME="latest"; fi'
script:
- |
curl --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file build/release/net.nosial.loglib.ncc \
"https://$CI_SERVER_HOST/api/v4/projects/$CI_PROJECT_ID/packages/generic/${PACKAGE_NAME}/${CI_COMMIT_SHA}/net.nosial.loglib.ncc"
publish_static:
stage: publish
before_script:
- 'if [ "$CI_COMMIT_REF_NAME" == "master" ]; then PACKAGE_NAME="latest"; fi'
script:
- |
curl --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file build/release/net.nosial.loglib_static.ncc \
"https://$CI_SERVER_HOST/api/v4/projects/$CI_PROJECT_ID/packages/generic/${PACKAGE_NAME}/${CI_COMMIT_SHA}/net.nosial.loglib_static.ncc"