Skip to content

Commit 75d0f1e

Browse files
authored
Suggest dplyv2 changes to .travis.yml as a note
This is following @ehuss' comment to not recommend something currently in beta release.
1 parent e310dfc commit 75d0f1e

File tree

1 file changed

+34
-4
lines changed

1 file changed

+34
-4
lines changed

guide/src/continuous-integration.md

Lines changed: 34 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@ run.
1212

1313
```yaml
1414
language: rust
15-
os: linux
16-
dist: xenial
15+
sudo: false
1716

1817
cache:
1918
- cargo
@@ -47,6 +46,39 @@ Then, append this snippet to your `.travis.yml` and update the path to the
4746
`book` directory:
4847

4948
```yaml
49+
deploy:
50+
provider: pages
51+
skip-cleanup: true
52+
github-token: $GITHUB_TOKEN
53+
local-dir: path/to/mybook/book
54+
keep-history: false
55+
on:
56+
branch: master
57+
```
58+
59+
That's it!
60+
61+
Note: Travis has a new [dplv2](https://blog.travis-ci.com/2019-08-27-deployment-tooling-dpl-v2-preview-release) configuration that is currently in beta. To use this new format, update your `.travis.yml` file to:
62+
63+
```yaml
64+
language: rust
65+
os: linux
66+
dist: xenial
67+
68+
cache:
69+
- cargo
70+
71+
rust:
72+
- stable
73+
74+
before_script:
75+
- (test -x $HOME/.cargo/bin/cargo-install-update || cargo install cargo-update)
76+
- (test -x $HOME/.cargo/bin/mdbook || cargo install --vers "^0.3" mdbook)
77+
- cargo install-update -a
78+
79+
script:
80+
- mdbook build path/to/mybook && mdbook test path/to/mybook
81+
5082
deploy:
5183
provider: pages
5284
strategy: git
@@ -60,8 +92,6 @@ deploy:
6092
target_branch: gh-pages
6193
```
6294

63-
That's it!
64-
6595
### Deploying to GitHub Pages manually
6696

6797
If your CI doesn't support GitHub pages, or you're deploying somewhere else

0 commit comments

Comments
 (0)