# Copyright (C) 2018-2020 Brian Douglass # Copyright (C) 2022 abmyii # Copyright (C) 2022-2023 Jonatan Hatakeyama Zeidler # Copyright (C) 2022 Guido Berhoerster # Copyright (C) 2023 Alexander Richards # # SPDX-License-Identifier: GPL-3.0-only # # This file is part of Lomiri Calculator App # # Lomiri Calculator App is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License version 3 as # published by the Free Software Foundation. # # Lomiri Calculator App is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . ############################################################################### # Define defaults and template anchors ############################################################################### variables: GIT_SUBMODULE_STRATEGY: recursive DOCKER_DRIVER: overlay2 CLICKABLE_VERSION: "8" UT_VERSION: "20.04" .node_anchors: amd64: &amd64 variables: ARCH: "amd64" ARCH_TRIPLET: "x86_64-linux-gnu" arm64: &arm64 variables: ARCH: "arm64" ARCH_TRIPLET: "aarch64-linux-gnu" armhf: &armhf variables: ARCH: "armhf" ARCH_TRIPLET: "arm-linux-gnueabihf" # https://stackoverflow.com/a/77477765 workflow: rules: - if: $CI_PROJECT_NAMESPACE =~ /^ubports\// variables: # Use our own GitLab runner RUNNER_TAG: "ubports" - if: $CI_PROJECT_NAMESPACE !~ /^ubports\// variables: # Use shared runner if run outside our namespace RUNNER_TAG: "saas-linux-small-amd64" default: tags: - $RUNNER_TAG image: "clickable/ci-$UT_VERSION-$ARCH:$CLICKABLE_VERSION" ############################################################################### # Define stages ############################################################################### stages: - build - publish ############################################################################### # `build` stage: build clicks for all architectures ############################################################################### .build: stage: build artifacts: expire_in: 1 week paths: - "build/$ARCH_TRIPLET/app" script: - clickable build --clean --accept-review-errors build-amd64: <<: *amd64 extends: .build build-arm64: <<: *arm64 extends: .build build-armhf: <<: *armhf extends: .build ############################################################################### # `publish` stage: upload to OpenStore on tags ############################################################################### publish: <<: *amd64 stage: publish artifacts: expire_in: 1 week paths: - build/x86_64-linux-gnu/app/*.click - build/aarch64-linux-gnu/app/*.click - build/arm-linux-gnueabihf/app/*.click rules: - if: $CI_COMMIT_TAG script: - 'clickable publish --arch amd64 -- "$CI_COMMIT_MESSAGE"' - 'clickable publish --arch arm64' - 'clickable publish --arch armhf'