mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-23 13:08:01 +00:00
Publish rustdocs to github pages (#562)
* Publish rustdocs to github pages * @TriplEight 's suggestions from code review Co-authored-by: Denis Pisarev <denis.pisarev@parity.io> Co-authored-by: Denis Pisarev <denis.pisarev@parity.io>
This commit is contained in:
@@ -0,0 +1,39 @@
|
||||
name: Publish Rust Docs
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
deploy-docs:
|
||||
name: Deploy docs
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/actions/checkout@v2.3.4
|
||||
|
||||
- name: Rust show versions
|
||||
run: rustup show
|
||||
|
||||
- name: Rust cache
|
||||
uses: Swatinem/rust-cache@v1
|
||||
|
||||
- name: Build rustdocs
|
||||
uses: actions-rs/cargo@v1
|
||||
with:
|
||||
command: doc
|
||||
args: --all --no-deps
|
||||
|
||||
# Make an index.html file that redirects to the cumulus-client-collator page
|
||||
# Copied from https://github.com/substrate-developer-hub/rustdocs/blob/master/index.html
|
||||
- name: Make index.html
|
||||
run: echo "<meta http-equiv=refresh content=0;url=cumulus_client_collator/index.html>" > ./target/doc/index.html
|
||||
|
||||
- name: Deploy documentation
|
||||
uses: peaceiris/actions-gh-pages@v3
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
publish_branch: gh-pages
|
||||
publish_dir: ./target/doc
|
||||
Reference in New Issue
Block a user