From 2540404b000397db43ef8b0077d4595f4890de71 Mon Sep 17 00:00:00 2001 From: Victor Porof Date: Thu, 19 Jul 2018 18:32:54 +0200 Subject: [PATCH] Generate rust documentation on CI and publish to gh-pages automatically (#793) Signed-off-by: Victor Porof --- .travis.yml | 8 ++++++++ README.md | 2 ++ 2 files changed, 10 insertions(+) diff --git a/.travis.yml b/.travis.yml index 39647641..d70d050b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,4 +23,12 @@ script: for manifest in $(find . -type f -name Cargo.toml); do cargo test --manifest-path $manifest --verbose --no-default-features --features sqlcipher done +after_success: + - | + if [[ "$TRAVIS_PULL_REQUEST" = "false" && "$TRAVIS_BRANCH" == "master" ]]; then + cargo doc && + echo "" > target/doc/index.html && + git clone https://github.com/davisp/ghp-import.git && + ./ghp-import/ghp_import.py -n -p -f -r https://"$GH_TOKEN"@github.com/"$TRAVIS_REPO_SLUG.git" target/doc + fi cache: cargo diff --git a/README.md b/README.md index 6f246ff6..05d51320 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,8 @@ The first version of Project Mentat, named Datomish, [was written in ClojureScri The Rust implementation gives us a smaller compiled output, better performance, more type safety, better tooling, and easier deployment into Firefox and mobile platforms. +[Documentation](https://mozilla.github.io/mentat) + --- ## Motivation