.gitlab-ci.yml 1.76 KB
Newer Older
Swann Perarnau's avatar
Swann Perarnau committed
1
variables:
Valentin Reis's avatar
Valentin Reis committed
2
  ARGOPKGS : "https://xgitlab.cels.anl.gov/argo/argopkgs/-/archive/master/argopkgs-master.tar.gz"
Swann Perarnau's avatar
Swann Perarnau committed
3

4
stages:
5
  - style
6
  - build
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
7
  - docs
8
  - release
9

Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
10 11 12 13 14 15 16 17 18
repoquality:
  stage: style
  script:
    - nix run -f "$ARGOPKGS" repoquality --command repoquality
  tags:
    - integration

checkpatch:
  stage: style
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
19 20
  tags:
    - integration
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
21 22 23
  script:
    - nix run -f "$ARGOPKGS" checkpatch --command checkpatch.pl

24 25
make:generic:
  stage: build
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
26 27 28
  except:
    - /^wip.*/
    - /^WIP.*/
29 30 31 32 33 34
  script:
    - ./autogen.sh
    - mkdir build
    - ./configure --prefix=`pwd`/build
    - make
    - make check
35
    - make install
36 37 38 39
  artifacts:
    when: on_failure
    paths:
      - tests/*.log
40 41 42

make:knl:
  stage: build
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
43 44 45 46 47
  except:
    - /^wip.*/
    - /^WIP.*/
  tags:
    - knl
48
  script:
49
    - source /opt/intel/compilers_and_libraries/linux/bin/compilervars.sh intel64
50 51
    - ./autogen.sh
    - mkdir build
52
    - CC=icc CFLAGS="-mkl -xhost" ./configure --prefix=`pwd`/build --enable-benchmarks
53
    - make -j64
54
    - make check
55
    - make install
56 57 58 59
  artifacts:
    when: on_failure
    paths:
      - tests/*.log
Swann Perarnau's avatar
Swann Perarnau committed
60

61
readthedocs:
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
62
  stage: docs
63 64 65
  when: on_success
  only:
    - master
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
66
    - /v[0-9]+\.[0-9]+\.x/
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
67 68
  tags:
    - integration
69 70
  script:
    - nix run nixpkgs.curl -c curl -X POST -d "branch=$CI_COMMIT_REF_NAME" -d "token=$READTHEDOCS_TOKEN" https://readthedocs.org/api/v2/webhook/argo-aml/83161/
71

Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
72
dist:
73 74 75 76
  stage: release
  when: on_success
  only:
    - tags
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
77 78
  tags:
    - integration    
79
  script:
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
80
    - nix-build "$ARGOPKGS" -A aml-dist --arg aml-src ./.
Nicolas Denoyelle's avatar
fix CI  
Nicolas Denoyelle committed
81
    - nix-shell "$ARGOPKGS" -A aml-dist --arg aml-src ./. --run  "./release.sh CREATE $CI_JOB_ID $CI_PROJECT_ID $RELEASE_TOKEN $CI_COMMIT_REF_NAME"
82 83 84 85 86 87
  artifacts:
    when: on_success
    paths:
      - result/*.tar.gz
      - CHECKSUM
    expire_in: 1000y
Nicolas Denoyelle's avatar
Nicolas Denoyelle committed
88