From 46223279b2e71c39ec0b48352fdf759a23f3316b Mon Sep 17 00:00:00 2001 From: Alberto Nidasio <alberto.nidasio@skywarder.eu> Date: Thu, 14 Mar 2024 08:29:10 +0000 Subject: [PATCH] [CI] Improved pipeline script with docker image --- .gitlab-ci.yml | 90 ++++++++++++++++++++++++-------------------------- 1 file changed, 44 insertions(+), 46 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5504eca86..ca918594d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,5 +1,5 @@ -# Copyright (c) 2021 Skyward Experimental Rocketry -# Authors: Luca Erbetta, Luca Conterio, Alberto Nidasio, Damiano Amatruda +# Copyright (c) 2024 Skyward Experimental Rocketry +# Authors: Luca Erbetta, Luca Conterio, Alberto Nidasio, Damiano Amatruda, Giacomo Caironi # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal @@ -22,84 +22,82 @@ variables: GIT_SUBMODULE_STRATEGY: recursive +default: + image: registry.skywarder.eu/avn/swd/docker/miosix:latest + stages: + - lint - build - test - - lint - documentation -# Stage build - -release: - stage: build - tags: - - miosix - script: - - ./sbs - -debug: - stage: build - tags: - - miosix - script: - - ./sbs --debug - -logdecoder: - stage: build - tags: - - miosix - script: - - cd scripts/logdecoder - - make - -# Stage test - -test: - stage: test - tags: - - miosix - script: - - ./sbs --test catch-tests-boardcore - # Stage lint cppcheck: stage: lint - tags: - - miosix script: + - cppcheck --version - ./scripts/linter.py --cppcheck src format: stage: lint - tags: - - miosix script: + - clang-tidy --version + - clang-format --version - ./scripts/linter.py --format src copyright: stage: lint - tags: - - miosix script: + - /usr/bin/python3 --version - ./scripts/linter.py --copyright src find: stage: lint - tags: - - miosix script: + - /usr/bin/python3 --version - ./scripts/linter.py --find src +# Stage build + +build-debug: + stage: build + script: + - cmake --version + - ccache --version + - ninja --version + - ./sbs --debug + +build-release: + stage: build + script: + - cmake --version + - ccache --version + - ninja --version + - ./sbs + +logdecoder: + stage: build + script: + - g++ --version + - cd scripts/logdecoder + - make + +# Stage test + +test: + stage: test + script: + - ./sbs --test catch-tests-boardcore + # Stage documentation pages: stage: documentation only: - main - tags: - - doxygen script: + - doxygen --version - doxygen doc/Doxyfile - mv doc/output/html public artifacts: -- GitLab