Skip to content

Commit

Permalink
Send repo and branch info into Docker builds
Browse files Browse the repository at this point in the history
  • Loading branch information
adamcandy committed Jul 11, 2018
1 parent 7cba602 commit ab8a035
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 10 deletions.
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ matrix:
dist: xenial
language: cpp
install:
- docker build -f Dockerfile_Bionic -t shingle .
- docker build -e REPO="$TRAVIS_REPO_SLUG" -e BRANCH="$TRAVIS_BRANCH" -f Dockerfile_Bionic -t shingle .
script:
- docker run -a stdout -t shingle make unittest
# Pre-download, to best work with Travis timeout
Expand All @@ -73,7 +73,7 @@ matrix:
dist: xenial
language: cpp
install:
- docker build -f Dockerfile_Xenial -t shingle .
- docker build -e REPO="$TRAVIS_REPO_SLUG" -e BRANCH="$TRAVIS_BRANCH" -f Dockerfile_Xenial -t shingle .
script:
- docker run -a stdout -t shingle make unittest
# Pre-download, to best work with Travis timeout
Expand All @@ -92,7 +92,7 @@ matrix:
dist: xenial
language: cpp
install:
- docker build -f Dockerfile_Trusty -t shingle .
- docker build -e REPO="$TRAVIS_REPO_SLUG" -e BRANCH="$TRAVIS_BRANCH" -f Dockerfile_Trusty -t shingle .
script:
- docker run -a stdout -t shingle make unittest
# Pre-download, to best work with Travis timeout
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile_Bionic
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ USER shingle
WORKDIR /home/shingle

# Make a copy of the project Shingle
RUN git clone https://github.com/shingle/Shingle.git
RUN git clone "https://github.com/${REPO}"
WORKDIR /home/shingle/Shingle
RUN git checkout master
RUN git checkout "$BRANCH"
RUN git pull

ENV PATH /home/shingle/Shingle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
Expand Down
5 changes: 3 additions & 2 deletions Dockerfile_Trusty
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,12 @@ USER shingle
WORKDIR /home/shingle

# Make a copy of the project Shingle
RUN git clone https://github.com/shingle/Shingle.git
RUN git clone "https://github.com/${REPO}"
WORKDIR /home/shingle/Shingle
RUN git checkout master
RUN git checkout "$BRANCH"
RUN git pull


ENV PATH /home/shingle/Shingle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

RUN make
Expand Down
5 changes: 3 additions & 2 deletions Dockerfile_Xenial
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,12 @@ USER shingle
WORKDIR /home/shingle

# Make a copy of the project Shingle
RUN git clone https://github.com/shingle/Shingle.git
RUN git clone "https://github.com/${REPO}"
WORKDIR /home/shingle/Shingle
RUN git checkout master
RUN git checkout "$BRANCH"
RUN git pull


ENV PATH /home/shingle/Shingle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

RUN make
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
#)

setup(name='shingle',
version='2.1.1',
version='2.1.2',
description='Generation of boundary representation and mesh spatial discretisations from arbitrary geophysical fields.',
author = 'Adam S. Candy',
author_email='[email protected]',
Expand Down

0 comments on commit ab8a035

Please sign in to comment.