summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-04-18 18:20:02 +0300
committerAndrei Karas <akaras@inbox.ru>2016-04-18 18:20:02 +0300
commit5678eca848f453993a63e8fb97f923862c700f7f (patch)
tree93842dfb9d21990a2ad1f4281f2433217c52d0cf
parentabbbaeac6a939e8db4cb3c27d606fccc9deb229c (diff)
downloadparanucker-5678eca848f453993a63e8fb97f923862c700f7f.tar.gz
paranucker-5678eca848f453993a63e8fb97f923862c700f7f.tar.bz2
paranucker-5678eca848f453993a63e8fb97f923862c700f7f.tar.xz
paranucker-5678eca848f453993a63e8fb97f923862c700f7f.zip
Add ci script, update .gitlab-ci.yml
-rw-r--r--.gitlab-ci.yml23
-rwxr-xr-xci/install.sh29
2 files changed, 49 insertions, 3 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 1ddfbd8..3bf14c9 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -1,8 +1,25 @@
-before_script:
- - gcc --version
- - uname -a
+stages:
+ - build
+ - success
+ - failure
job1:
stage: build
+ image: debian:unstable
script:
+ - ./ci/install.sh
- ./build.sh
+
+success:
+ stage: success
+ script:
+ - echo "do nothing"
+ image: debian:unstable
+ when: on_success
+
+failure:
+ stage: failure
+ script:
+ - echo "do nothing"
+ image: debian:unstable
+ when: on_failure
diff --git a/ci/install.sh b/ci/install.sh
new file mode 100755
index 0000000..d143bf3
--- /dev/null
+++ b/ci/install.sh
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+
+function aptget_update {
+ apt-get update
+ if [ "$?" != 0 ]; then
+ sleep 1s
+ apt-get update
+ if [ "$?" != 0 ]; then
+ sleep 1s
+ apt-get update
+ fi
+ fi
+}
+
+function aptget_install {
+ apt-get -y -qq install $*
+ if [ "$?" != 0 ]; then
+ sleep 1s
+ apt-get -y -qq install $*
+ if [ "$?" != 0 ]; then
+ sleep 2s
+ apt-get -y -qq install $*
+ fi
+ fi
+}
+
+aptget_update
+aptget_install gcc g++ gcc-5 g++-5 gcc-5-plugin-dev