Skip to content

Commit

Permalink
Begin work on docs book (#156)
Browse files Browse the repository at this point in the history
* init mdbook

* Add workflow

* trigger ci

* fix install

* re-trigger

* fix typo

* fix working dir

* fix working dir
  • Loading branch information
makspll authored Dec 3, 2024
1 parent c76b062 commit 85aa070
Show file tree
Hide file tree
Showing 6 changed files with 55 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/bevy_mod_scripting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
- '.github/workflows/release-plz.yml'
- '.github/workflows/bevy_api_gen.yml'
- '.github/workflows/macro_tests.yml'
- 'docs/**'


name: Check and Lint - bevy_mod_scripting
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/mdbook.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Deploy mdBook to GitHub Pages

on:
push:
branches:
- "**"
paths:
- 'docs/**'
- '.github/workflows/mdbook.yml'

jobs:

build:
name: Build Book - mdbook
runs-on: ubuntu-latest
steps:

- name: Checkout repository
uses: actions/checkout@v4

- uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: Rust Cache
uses: Swatinem/[email protected]
- name: Install mdBook
run: cargo install mdbook

- name: Build the book
run: cd docs && mdbook build

- name: Deploy to GitHub Pages
if: github.ref == 'refs/heads/main'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/book
1 change: 1 addition & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
book
6 changes: 6 additions & 0 deletions docs/book.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[book]
authors = ["makspll"]
language = "en"
multilingual = false
src = "src"
title = "Bevy Scripting"
3 changes: 3 additions & 0 deletions docs/src/SUMMARY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Summary

- [Chapter 1](./chapter_1.md)
6 changes: 6 additions & 0 deletions docs/src/chapter_1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Chapter 1


## Introduction

Welcome to the greatest documentation of all time WIP

0 comments on commit 85aa070

Please sign in to comment.