Skip to content

Commit c66175b

Browse files
authored
Merge pull request #17 from dvanhorn/next
Build on OSX (and Linux) on Travis CI; Rewrite Dupe
2 parents 36da8ff + 314aac0 commit c66175b

7 files changed

Lines changed: 475 additions & 104 deletions

File tree

.travis.yml

Lines changed: 21 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
language: generic
22
sudo: required
33
dist: trusty
4+
os:
5+
- linux
6+
- osx
7+
48
env:
59
global:
610
- RACKET_DIR=~/racket
@@ -9,22 +13,29 @@ env:
913
- PANDOC_DEB="https://github.com/jgm/pandoc/releases/download/2.7.3/pandoc-2.7.3-1-amd64.deb"
1014
matrix:
1115
- RACKET_VERSION=7.4
16+
1217
cache:
1318
directories:
1419
- $PANDOC
20+
1521
before_install:
1622
- mkdir -p "$PANDOC"
17-
- if [[ ! -f "$PANDOC/pandoc.deb" ]]; then curl -L "$PANDOC_DEB" > "$PANDOC/pandoc.deb" && dpkg -x "$PANDOC/pandoc.deb" "$PANDOC"; fi
18-
- export PATH="$PANDOC/usr/bin:$PATH"
19-
- git clone https://github.com/greghendershott/travis-racket.git
20-
- cat travis-racket/install-racket.sh | bash
21-
- export PATH="${RACKET_DIR}/bin:${PATH}"
22-
- sudo apt-get install -y nasm
23+
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then if [[ ! -f "$PANDOC/pandoc.deb" ]]; then curl -L "$PANDOC_DEB" > "$PANDOC/pandoc.deb" && dpkg -x "$PANDOC/pandoc.deb" "$PANDOC"; fi ; fi
24+
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then export PATH="$PANDOC/usr/bin:$PATH"; fi
25+
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then git clone https://github.com/greghendershott/travis-racket.git; fi
26+
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then cat travis-racket/install-racket.sh | bash; fi
27+
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then export PATH="${RACKET_DIR}/bin:${PATH}"; fi
28+
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then sudo apt-get install -y nasm; fi
29+
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew cask install racket; fi
30+
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew install nasm; fi
31+
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew install pandoc; fi
32+
2333
install:
34+
2435
before_script:
25-
- export DISPLAY=:99.0
26-
- sh -e /etc/init.d/xvfb start
27-
- sleep 3
36+
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then export DISPLAY=:99.0; fi
37+
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then sh -e /etc/init.d/xvfb start; fi
38+
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then sleep 3; fi
2839

2940
script:
3041
- raco make www/main.scrbl
@@ -46,4 +57,5 @@ deploy:
4657
script: rsync -rvzp $TRAVIS_BUILD_DIR/www/cmsc430 dvanhorn@junkfood.cs.umd.edu:$WWW_DIR/fall2019
4758
on:
4859
branch: master
60+
condition: "$TRAVIS_OS_NAME = linux"
4961

0 commit comments

Comments
 (0)