From 994e50b52617938189d426c3c31cd08efaef4ca9 Mon Sep 17 00:00:00 2001
From: Mohcine Chraibi <m.chraibi@fz-juelich.de>
Date: Fri, 5 Apr 2019 19:24:47 +0000
Subject: [PATCH] Add new file

---
 .gitlab-ci.yml | 55 ++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 55 insertions(+)
 create mode 100644 .gitlab-ci.yml

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 0000000..81132e6
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,55 @@
+variables:
+  nproc: "1"
+
+
+before_script:
+  - nproc=`grep -c '^processor' /proc/cpuinfo`
+  - echo "nproc = $nproc"
+
+#========== Pipeline ==================
+stages:
+  - configure
+  - compile
+#=====================================
+
+#============== configure ============
+configure-linux:
+  artifacts:
+    name: "${CI_BUILD_NAME}_${CI_BUILD_ID}"
+    expire_in: 1 hour
+    paths:
+      - build
+      - lib
+      - lib/Debug
+      - bin
+  script:
+    - mkdir -p build
+    - cd build
+    - cmake   ..
+    - echo "configure | ${CI_PROJECT_DIR}"
+  stage: configure
+  tags:
+    - linux
+#============== compile ============
+make-linux:
+  dependencies:
+    - configure-linux
+  artifacts:
+    name: "${CI_BUILD_NAME}_${CI_BUILD_ID}"
+    expire_in: 1 hour # optional expiry
+    paths:
+      - build
+      - bin
+      - lib
+      - lib/Debug
+
+  stage: compile
+  script:
+    - cd build
+    - make -j$nproc
+    - echo "compile | ${CI_PROJECT_DIR}"
+  tags:
+    - linux
+
+after_script:
+  - echo "End CI" # todo: run report script
-- 
GitLab