gitlab-ci.yml 1.4 KB
Newer Older
Shivani Bhardwaj's avatar
Shivani Bhardwaj committed
1 2
# A comment
#
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42
stages:
    - build-paper-icon-theme

# These steps will run before each build.
# They are included here to avoid repetition of same code on later stages.
# similar to a macro

before_script:
   - export DEBIAN_FRONTEND=noninteractive
   - echo "Preparing the container for builds"
   - apt update
   - apt-get -y upgrade
   - apt-get -y dist-upgrade
   - apt-get -y install apt-utils figlet dpkg-dev fakeroot git-buildpackage lintian pristine-tar
   - figlet BUILD

#----------------------------------------------------------------------------------------------------------------

build-paper-icon-theme:
    stage: build-paper-icon-theme
    image:
        name: rajudev/hamara-builder:amd64
    allow_failure: true
    dependencies: []

    script:
        - cd packages/paper-icon-theme
        - export BUILD_DEPENDS=`perl -ne 'next if /^#/; $p=(s/^Build-Depends:\s*/ / or (/^ / and $p)); s/,|\n|\([^)]+\)//mg; print if $p' < debian/control`
        - apt-get install -y --no-install-recommends $BUILD_DEPENDS
        - apt-get -y autoremove --purge
        - apt-get clean
        - rm -rf /var/lib/apt/lists/*
        - dpkg-buildpackage -us -uc
        - ls -al / # test the directory structure presence
          # - echo "Deploying packages to repositories"
          # - cp ../*.deb ../*.dsc ../*.changes ../*.tar.* ../*.buildinfo /incoming/

    artifacts:
        untracked: true
        expire_in: 1 day