mirror of
https://gitlab.cern.ch/wotsubo/PSBoardDataBase.git
synced 2025-06-08 14:05:40 +09:00
71 lines
1.8 KiB
YAML
71 lines
1.8 KiB
YAML
.script:
|
|
script:
|
|
- |
|
|
julia --project=@. -e '
|
|
using Pkg
|
|
Pkg.build()
|
|
Pkg.test(coverage=true)'
|
|
.coverage:
|
|
coverage: /Test coverage (\d+\.\d+%)/
|
|
after_script:
|
|
- |
|
|
julia -e '
|
|
using Pkg
|
|
Pkg.add("Coverage")
|
|
using Coverage
|
|
c, t = get_summary(process_folder())
|
|
using Printf
|
|
@printf "Test coverage %.2f%%\n" 100c / t'
|
|
Julia 1.10:
|
|
image: julia:1.10
|
|
extends:
|
|
- .script
|
|
- .coverage
|
|
pages:
|
|
image: julia:1.10
|
|
stage: deploy
|
|
script:
|
|
- |
|
|
julia --project=docs -e '
|
|
using Pkg
|
|
Pkg.develop(PackageSpec(path=pwd()))
|
|
Pkg.instantiate()
|
|
using Documenter: doctest
|
|
using PSBoardDataBase
|
|
doctest(PSBoardDataBase)
|
|
include("docs/make.jl")'
|
|
- mkdir -p public
|
|
- mv docs/build public/dev
|
|
artifacts:
|
|
paths:
|
|
- public
|
|
rules:
|
|
# https://gitlab-docs.creationline.com/ee/ci/jobs/job_control.html#specify-when-jobs-run-with-rules
|
|
- if: $CI_COMMIT_BRANCH == "main" # when pushed to main
|
|
- if: $CI_COMMIT_TAG
|
|
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
|
|
# only:
|
|
# - main
|
|
CompatHelper:
|
|
image: julia:1.10 # Set to the Julia version you want to use
|
|
stage: test # You can place this in any stage that makes sense for your setup
|
|
only:
|
|
- schedules
|
|
before_script:
|
|
- apt-get update -qq && apt-get install -y git
|
|
- |
|
|
julia --color=yes -e "
|
|
import Pkg;
|
|
name = \"CompatHelper\";
|
|
uuid = \"aa819f21-2bde-4658-8897-bab36330d9b7\";
|
|
version = \"3\";
|
|
Pkg.add(; name, uuid, version)"
|
|
script:
|
|
- |
|
|
julia --color=yes -e '
|
|
import CompatHelper;
|
|
config = CompatHelper.GitLabCI(;
|
|
api_hostname="https://gitlab.cern.ch/api/v4",
|
|
clone_hostname="gitlab.cern.ch",
|
|
)
|
|
CompatHelper.main(ENV, config)'
|