diff --git a/.travis.yml b/.travis.yml index f468f234..eaf4224d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,25 +6,25 @@ os: julia: - 0.4 #- nightly -# -# -# # addons: -# # apt: -# # packages: -# # - wkhtmltopdf -# # + + # # before install: # # - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update ; fi # # - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install wkhtmltopdf; fi -# -# + +# ref: http://askubuntu.com/a/556672 for the wkhtmltopdf apt repository info + sudo: required before_install: - - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo add-apt-repository -y ppa:pov/wkhtmltopdf ; fi - - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get -qq update ; fi - - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get install -y wkhtmltopdf ; fi - - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then wkhtmltopdf -V ; fi - - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then wkhtmltoimage -V ; fi + - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then pwd ; fi + - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then ./install_wkhtmltoimage.sh ; fi +# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo add-apt-repository -y ppa:pov/wkhtmltopdf ; fi +# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get -qq update ; fi +# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get install -y wkhtmltopdf ; fi +# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then wkhtmltopdf -V ; fi +# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then wkhtmltoimage -V ; fi +# echo 'exec xvfb-run -a -s "-screen 0 640x480x16" wkhtmltopdf "$@"' | sudo tee /usr/local/bin/wkhtmltopdf.sh >/dev/null +# sudo chmod a+x /usr/local/bin/wkhtmltopdf.sh # # borrowed from Blink.jl's travis file # matrix: @@ -36,14 +36,6 @@ before_install: # julia: 0.4 # env: TESTCMD="julia" -# matrix: -# include: -# - os: linux -# sudo: required -# before_install: -# - sudo apt-get -qq update -# - sudo apt-get install -y wkhtmltopdf -# - os: osx notifications: @@ -52,16 +44,12 @@ notifications: script: - if [[ -a .git/shallow ]]; then git fetch --unshallow; fi - julia -e 'Pkg.clone(pwd()); Pkg.build("Plots")' - # - julia -e 'Pkg.clone("https://github.com/tbreloff/Images.jl.git"); Pkg.checkout("Images","tom_imgcompare");' - # - julia -e 'Pkg.clone("Images"); Pkg.build("Images")' - julia -e 'Pkg.clone("ImageMagick"); Pkg.build("ImageMagick")' - julia -e 'Pkg.clone("GR"); Pkg.build("GR")' # - julia -e 'Pkg.clone("https://github.com/tbreloff/ImageMagick.jl.git"); Pkg.checkout("ImageMagick","tb_write"); Pkg.build("ImageMagick")' - # - julia -e 'Pkg.clone("https://github.com/tbreloff/VisualRegressionTests.jl.git");' - julia -e 'Pkg.clone("https://github.com/tbreloff/ExamplePlots.jl.git");' # - julia -e 'Pkg.clone("https://github.com/JunoLab/Blink.jl.git"); Pkg.build("Blink"); import Blink; Blink.AtomShell.install()' # - julia -e 'Pkg.clone("https://github.com/spencerlyon2/PlotlyJS.jl.git")' - # - julia -e 'Pkg.add("Cairo"); Pkg.build("Cairo")' - julia -e 'ENV["PYTHON"] = ""; Pkg.add("PyPlot"); Pkg.build("PyPlot")' # - $TESTCMD -e 'Pkg.test("Plots"; coverage=false)' diff --git a/test/install_wkhtmltoimage.sh b/test/install_wkhtmltoimage.sh new file mode 100644 index 00000000..bba78215 --- /dev/null +++ b/test/install_wkhtmltoimage.sh @@ -0,0 +1,8 @@ +set -e +sudo add-apt-repository -y ppa:pov/wkhtmltopdf +sudo apt-get -qq update +sudo apt-get install -y wkhtmltopdf +wkhtmltopdf -V +wkhtmltoimage -V +echo 'exec xvfb-run -a -s "-screen 0 640x480x16" wkhtmltoimage "$@"' | sudo tee /usr/local/bin/wkhtmltoimage.sh >/dev/null +sudo chmod a+x /usr/local/bin/wkhtmltoimage.sh