variables:
RELEASES: |
v0.1=0.1.0-alpha-6
v0.1=0.1.0-alpha-5
v0.1=0.1.0-alpha-4
v0.1=0.1.0-alpha-3
v0.1=0.1.0-alpha-2
v0.1=0.1.0-alpha
image: "debian:testing"
before_script:
- apt update; apt install -y --no-install-recommends git build-essential ca-certificates meson cmake libgtk-4-dev libnghttp2-dev libsqlite3-dev libpsl-dev glib-networking curl
- git clone --recursive https://gitlab.gnome.org/GNOME/libsoup
- cd libsoup
- meson build -Dprefix=/usr -Dbrotli=enabled -Ddocs=disabled -Dinstalled_tests=false -Dvapi=disabled
- cd build
- ninja install
- cd ../../
- curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain none -y
- source $HOME/.cargo/env
- rustup toolchain install nightly --profile minimal --allow-downgrade -c rustfmt
- git submodule update --init
- curl --proto '=https' --tlsv1.2 -sSf -o gir-rustdoc.py
https://gitlab.gnome.org/World/Rust/gir-rustdoc/-/raw/main/gir-rustdoc.py
- chmod +x gir-rustdoc.py
build:
script:
- cargo build --all-features --examples
- cargo test
docs:
stage: test
variables:
GIT_SUBMODULE_STRATEGY: recursive
script:
- cargo install rustdoc-stripper
- ./generator.py --embed-docs
- rustup default nightly
- eval $(./gir-rustdoc.py pre-docs)
- cargo doc --features dox --no-deps
- mv target/doc/ docs
artifacts:
paths:
- docs
pages:
stage: deploy
script:
- ./gir-rustdoc.py html-index
- mkdir public/git
- mv docs public/git/docs
artifacts:
paths:
- public
rules:
- if: $CI_DEFAULT_BRANCH == $CI_COMMIT_BRANCH