gitlabci: add flatpak build and reformat tabs.
This commit is contained in:
parent
a253d7ebf5
commit
bc2da6e59e
@ -2,44 +2,56 @@ stages:
|
|||||||
- test
|
- test
|
||||||
- lint
|
- lint
|
||||||
|
|
||||||
variables:
|
|
||||||
# RUSTFLAGS: "-C link-dead-code"
|
|
||||||
RUST_BACKTRACE: "FULL"
|
|
||||||
|
|
||||||
.cargo_test_template: &cargo_test
|
.cargo_test_template: &cargo_test
|
||||||
stage: test
|
stage: test
|
||||||
|
|
||||||
before_script:
|
# variables:
|
||||||
- apt-get update -yqq
|
# RUSTFLAGS: "-C link-dead-code"
|
||||||
- apt-get install -yqq --no-install-recommends build-essential libgtk-3-dev meson
|
# RUST_BACKTRACE: "FULL"
|
||||||
script:
|
|
||||||
- rustc -Vv && cargo -Vv
|
|
||||||
# Force regeneration of gresources regardless of artifacts chage
|
|
||||||
- cd hammond-gtk/resources/ && glib-compile-resources --generate resources.xml && cd ../../
|
|
||||||
|
|
||||||
- cargo build
|
before_script:
|
||||||
- cargo test -- --test-threads=1
|
- apt-get update -yqq
|
||||||
- cargo test -- --test-threads=1 --ignored
|
- apt-get install -yqq --no-install-recommends build-essential libgtk-3-dev meson
|
||||||
|
script:
|
||||||
|
- rustc -Vv && cargo -Vv
|
||||||
|
# Force regeneration of gresources regardless of artifacts chage
|
||||||
|
- cd hammond-gtk/resources/ && glib-compile-resources --generate resources.xml && cd ../../
|
||||||
|
|
||||||
|
- cargo build
|
||||||
|
- cargo test -- --test-threads=1
|
||||||
|
- cargo test -- --test-threads=1 --ignored
|
||||||
|
|
||||||
stable:test:
|
stable:test:
|
||||||
# https://hub.docker.com/_/rust/
|
# https://hub.docker.com/_/rust/
|
||||||
image: "rust"
|
image: "rust"
|
||||||
<<: *cargo_test
|
<<: *cargo_test
|
||||||
|
|
||||||
# nightly:test:
|
# nightly:test:
|
||||||
# # https://hub.docker.com/r/rustlang/rust/
|
# https://hub.docker.com/r/rustlang/rust/
|
||||||
# image: "rustlang/rust:nightly"
|
# image: "rustlang/rust:nightly"
|
||||||
# <<: *cargo_test
|
# <<: *cargo_test
|
||||||
|
|
||||||
|
flatpak:
|
||||||
|
image: flatpak/flatpak-builder:gnome-3-28
|
||||||
|
stage: test
|
||||||
|
script:
|
||||||
|
- flatpak-builder --force-clean --repo=repo app org.gnome.Hammond.json
|
||||||
|
- flatpak build-bundle repo hammond-dev.flatpak org.gnome.hammond
|
||||||
|
artifacts:
|
||||||
|
paths:
|
||||||
|
- hammond-dev.flatpak
|
||||||
|
expire_in: 2 days
|
||||||
|
|
||||||
# Configure and run rustfmt on nightly
|
# Configure and run rustfmt on nightly
|
||||||
# Exits and builds fails if on bad format
|
# Exits and builds fails if on bad format
|
||||||
rustfmt:
|
rustfmt:
|
||||||
image: "registry.gitlab.com/alatiera/rustfmt-oci-image/rustfmt:nightly"
|
image: "registry.gitlab.com/alatiera/rustfmt-oci-image/rustfmt:nightly"
|
||||||
stage: lint
|
stage: lint
|
||||||
script:
|
script:
|
||||||
- rustc -Vv && cargo -Vv
|
- rustc -Vv && cargo -Vv
|
||||||
- cargo fmt --version
|
- cargo fmt --version
|
||||||
- cargo fmt --all -- --write-mode=diff
|
- cargo fmt --all -- --write-mode=diff
|
||||||
|
|
||||||
# Configure and run clippy on nightly
|
# Configure and run clippy on nightly
|
||||||
# Only fails on errors atm.
|
# Only fails on errors atm.
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user