From 61f9c89df2f0f02233fa26abc9a08f39e5e6ddd7 Mon Sep 17 00:00:00 2001 From: Cael Date: Sat, 24 Feb 2024 21:03:42 +0800 Subject: [PATCH] docs: recongnize docs example --- .github/workflows/page.yaml | 6 +++--- Cargo.toml | 1 + {example => docs}/assets/bin/mdbook | Bin {example => docs}/assets/css/patch.css | 0 {example => docs}/book.toml | 4 ++-- {example => docs}/src/SUMMARY.md | 6 +++--- {example => docs}/src/global-embedding.md | 0 {example => docs}/src/ignore-embeds.md | 0 example/src/intro.md => docs/src/index.md | 0 {example => docs}/src/local/announcement-banner.md | 0 {example => docs}/src/local/footer.md | 0 .../src/local/intro.md => docs/src/local/index.md | 0 {example => docs}/src/local/scroll-to-top.md | 0 {example => docs}/src/third-party/bilibili.md | 0 {example => docs}/src/third-party/codepen.md | 0 {example => docs}/src/third-party/codesandbox.md | 0 {example => docs}/src/third-party/giscus.md | 0 {example => docs}/src/third-party/gist.md | 0 .../intro.md => docs/src/third-party/index.md | 0 {example => docs}/src/third-party/stackblitz.md | 0 {example => docs}/src/third-party/youtube.md | 0 {example => docs}/src/usage.md | 0 22 files changed, 9 insertions(+), 8 deletions(-) rename {example => docs}/assets/bin/mdbook (100%) rename {example => docs}/assets/css/patch.css (100%) rename {example => docs}/book.toml (92%) rename {example => docs}/src/SUMMARY.md (84%) rename {example => docs}/src/global-embedding.md (100%) rename {example => docs}/src/ignore-embeds.md (100%) rename example/src/intro.md => docs/src/index.md (100%) rename {example => docs}/src/local/announcement-banner.md (100%) rename {example => docs}/src/local/footer.md (100%) rename example/src/local/intro.md => docs/src/local/index.md (100%) rename {example => docs}/src/local/scroll-to-top.md (100%) rename {example => docs}/src/third-party/bilibili.md (100%) rename {example => docs}/src/third-party/codepen.md (100%) rename {example => docs}/src/third-party/codesandbox.md (100%) rename {example => docs}/src/third-party/giscus.md (100%) rename {example => docs}/src/third-party/gist.md (100%) rename example/src/third-party/intro.md => docs/src/third-party/index.md (100%) rename {example => docs}/src/third-party/stackblitz.md (100%) rename {example => docs}/src/third-party/youtube.md (100%) rename {example => docs}/src/usage.md (100%) diff --git a/.github/workflows/page.yaml b/.github/workflows/page.yaml index b18683a..ef532c4 100644 --- a/.github/workflows/page.yaml +++ b/.github/workflows/page.yaml @@ -33,10 +33,10 @@ jobs: - name: Build book run: | - cp example/assets/bin/* /usr/local/bin && chmod u+x /usr/local/bin/mdbook* - cargo build --release && mdbook build example + chmod u+x docs/assets/bin/* && cp docs/assets/bin/* /usr/local/bin + cargo build --release && mdbook build docs - uses: peaceiris/actions-gh-pages@v3 with: github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: ./example/book + publish_dir: ./docs/book diff --git a/Cargo.toml b/Cargo.toml index 5944729..1a9abb8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,6 +4,7 @@ version = "0.2.7" edition = "2021" license = "MIT" readme = "README.md" +exclude = ["docs/*"] keywords = ["mdbook", "embed", "plugin"] authors = ["MR-Addict "] repository = "https://github.com/MR-Addict/mdbook-embedify" diff --git a/example/assets/bin/mdbook b/docs/assets/bin/mdbook similarity index 100% rename from example/assets/bin/mdbook rename to docs/assets/bin/mdbook diff --git a/example/assets/css/patch.css b/docs/assets/css/patch.css similarity index 100% rename from example/assets/css/patch.css rename to docs/assets/css/patch.css diff --git a/example/book.toml b/docs/book.toml similarity index 92% rename from example/book.toml rename to docs/book.toml index f520537..0ede665 100644 --- a/example/book.toml +++ b/docs/book.toml @@ -4,7 +4,7 @@ description = "This is a mdbook preprocessor plugin that allows you embed apps t language = "en" multilingual = false src = "src" -title = "Mdbook Embedify" +title = "mdbook-embedify" [build] build-dir = "book" @@ -47,7 +47,7 @@ command = "target/release/mdbook-embedify" scroll-to-top.enable = true footer.enable = true -footer.message = "Copyright © 2024 ❤️ By [MR-Addict](https://github.com/MR-Addict)" +footer.message = "Copyright © 2024 • Created with ❤️ by [MR-Addict](https://github.com/MR-Addict)" announcement-banner.enable = true announcement-banner.id = "0.2.7" diff --git a/example/src/SUMMARY.md b/docs/src/SUMMARY.md similarity index 84% rename from example/src/SUMMARY.md rename to docs/src/SUMMARY.md index 86fff9f..1270ff0 100644 --- a/example/src/SUMMARY.md +++ b/docs/src/SUMMARY.md @@ -2,14 +2,14 @@ # Basics -- [Intro](intro.md) +- [Intro](index.md) - [Usage](usage.md) - [Ignore Embeds](ignore-embeds.md) - [Global Embedding](global-embedding.md) # Apps -- [Third Party Apps](third-party/intro.md) +- [Third Party Apps](third-party/index.md) - [Gist](third-party/gist.md) - [Giscus](third-party/giscus.md) - [Youtube](third-party/youtube.md) @@ -17,7 +17,7 @@ - [Stackblitz](third-party/stackblitz.md) - [Codesandbox](third-party/codesandbox.md) - [Bilibili](third-party/bilibili.md) -- [Local Apps](local/intro.md) +- [Local Apps](local/index.md) - [Footer](local/footer.md) - [Scroll to Top](local/scroll-to-top.md) - [Announcement Banner](local/announcement-banner.md) diff --git a/example/src/global-embedding.md b/docs/src/global-embedding.md similarity index 100% rename from example/src/global-embedding.md rename to docs/src/global-embedding.md diff --git a/example/src/ignore-embeds.md b/docs/src/ignore-embeds.md similarity index 100% rename from example/src/ignore-embeds.md rename to docs/src/ignore-embeds.md diff --git a/example/src/intro.md b/docs/src/index.md similarity index 100% rename from example/src/intro.md rename to docs/src/index.md diff --git a/example/src/local/announcement-banner.md b/docs/src/local/announcement-banner.md similarity index 100% rename from example/src/local/announcement-banner.md rename to docs/src/local/announcement-banner.md diff --git a/example/src/local/footer.md b/docs/src/local/footer.md similarity index 100% rename from example/src/local/footer.md rename to docs/src/local/footer.md diff --git a/example/src/local/intro.md b/docs/src/local/index.md similarity index 100% rename from example/src/local/intro.md rename to docs/src/local/index.md diff --git a/example/src/local/scroll-to-top.md b/docs/src/local/scroll-to-top.md similarity index 100% rename from example/src/local/scroll-to-top.md rename to docs/src/local/scroll-to-top.md diff --git a/example/src/third-party/bilibili.md b/docs/src/third-party/bilibili.md similarity index 100% rename from example/src/third-party/bilibili.md rename to docs/src/third-party/bilibili.md diff --git a/example/src/third-party/codepen.md b/docs/src/third-party/codepen.md similarity index 100% rename from example/src/third-party/codepen.md rename to docs/src/third-party/codepen.md diff --git a/example/src/third-party/codesandbox.md b/docs/src/third-party/codesandbox.md similarity index 100% rename from example/src/third-party/codesandbox.md rename to docs/src/third-party/codesandbox.md diff --git a/example/src/third-party/giscus.md b/docs/src/third-party/giscus.md similarity index 100% rename from example/src/third-party/giscus.md rename to docs/src/third-party/giscus.md diff --git a/example/src/third-party/gist.md b/docs/src/third-party/gist.md similarity index 100% rename from example/src/third-party/gist.md rename to docs/src/third-party/gist.md diff --git a/example/src/third-party/intro.md b/docs/src/third-party/index.md similarity index 100% rename from example/src/third-party/intro.md rename to docs/src/third-party/index.md diff --git a/example/src/third-party/stackblitz.md b/docs/src/third-party/stackblitz.md similarity index 100% rename from example/src/third-party/stackblitz.md rename to docs/src/third-party/stackblitz.md diff --git a/example/src/third-party/youtube.md b/docs/src/third-party/youtube.md similarity index 100% rename from example/src/third-party/youtube.md rename to docs/src/third-party/youtube.md diff --git a/example/src/usage.md b/docs/src/usage.md similarity index 100% rename from example/src/usage.md rename to docs/src/usage.md