aboutsummaryrefslogtreecommitdiff
path: root/nitrocli/ci
diff options
context:
space:
mode:
authorDaniel Mueller <deso@posteo.net>2018-12-17 18:34:46 -0800
committerDaniel Mueller <deso@posteo.net>2018-12-17 18:34:46 -0800
commit14f6e9070ec2c1d4dad6afe32928133eaa0f3f67 (patch)
tree50f3e09ef35e4343c42185caf72f47b5bfda18d0 /nitrocli/ci
parent97accf1ddd79bb69dfb74742a0518c40830657e4 (diff)
downloadnitrocli-14f6e9070ec2c1d4dad6afe32928133eaa0f3f67.tar.gz
nitrocli-14f6e9070ec2c1d4dad6afe32928133eaa0f3f67.tar.bz2
Enable rustfmt in the CI pipeline
This change enables automated code format checking by means of the rustfmt program in the Gitlab CI pipeline. The check is performed in a third job in the hope that this helps identify problems more easily: users can see which of the jobs failed and focus on them in isolation, as opposed to having a single log file or, worse, just the results of the stages up to the first failure. This patch resolves issue #17.
Diffstat (limited to 'nitrocli/ci')
-rw-r--r--nitrocli/ci/gitlab-ci.yml6
1 files changed, 6 insertions, 0 deletions
diff --git a/nitrocli/ci/gitlab-ci.yml b/nitrocli/ci/gitlab-ci.yml
index d2301a3..c51a6bd 100644
--- a/nitrocli/ci/gitlab-ci.yml
+++ b/nitrocli/ci/gitlab-ci.yml
@@ -27,3 +27,9 @@ lint:clippy:
-A warnings -A clippy::float_cmp -A clippy::cast_ptr_alignment
- cargo clean --package=nitrocli
- cargo clippy --all-targets --all-features -- -D warnings
+
+format:rustfmt:
+ script:
+ - rustup component add rustfmt
+ - cd nitrocli
+ - cargo fmt --all -- --check