New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic deployment using Travis CI #26

Closed
pat-s opened this Issue Jan 3, 2017 · 2 comments

Comments

Projects
None yet
3 participants
@pat-s

pat-s commented Jan 3, 2017

@yihui Referring to your comment: http://disq.us/p/1eyc771

Is there already a setup for Travis CI to use automatic deployment? Your travis.yml does not seem to do deployment right now?
ATM I´m using wercker as this is suggested by Hugo. While this works using a "two repo" solution with Github pages, the deploy script does not support .Rmd files but only .md files.

Wercker.yml

box: golang:latest

build:
  steps:
    - script:
        name: initialize and update git submodules
        code: |
            git submodule init
            git submodule update --remote --recursive
    - arjen/hugo-build:
        version: "HEAD"
        theme: academic

deploy:
  steps:
    - install-packages:
            packages: git
    - leipert/git-push:
            gh_oauth: $GIT_TOKEN
            repo: pat-s/pat-s.github.io
            branch: master
            basedir: public
@dfalbel

This comment has been minimized.

Show comment
Hide comment
@dfalbel

dfalbel Jan 3, 2017

@jtrecenti have done this here: https://github.com/curso-r/verao2017

basicaly, we changed .travis.yml to this:

language: r
cache: packages


before_script:
  - chmod +x ./_build.sh
  - chmod +x ./_deploy.sh

script:
  - ./_build.sh
  - ./_deploy.sh
  • Added a DESCRIPTION file, so travis thinks it's an R package

See also _build.sh, _deploy.sh and build.R files.
You also need to add a github path to Travis

dfalbel commented Jan 3, 2017

@jtrecenti have done this here: https://github.com/curso-r/verao2017

basicaly, we changed .travis.yml to this:

language: r
cache: packages


before_script:
  - chmod +x ./_build.sh
  - chmod +x ./_deploy.sh

script:
  - ./_build.sh
  - ./_deploy.sh
  • Added a DESCRIPTION file, so travis thinks it's an R package

See also _build.sh, _deploy.sh and build.R files.
You also need to add a github path to Travis

@yihui

This comment has been minimized.

Show comment
Hide comment
@yihui

yihui Jul 26, 2017

Member

I forgot to mention that I had documented this at https://bookdown.org/yihui/blogdown/travis-github.html. Using the native support for Github Pages on Travis may be a better idea than a custom shell script _deploy.sh.

Member

yihui commented Jul 26, 2017

I forgot to mention that I had documented this at https://bookdown.org/yihui/blogdown/travis-github.html. Using the native support for Github Pages on Travis may be a better idea than a custom shell script _deploy.sh.

@yihui yihui closed this Jul 26, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment