Repository: axodotdev/cargo-dist
Pull request #53 (2023-01-27 04:25:10)

doc: add oranda


Patch:
diff --git a/.github/workflows/book.yml b/.github/workflows/book.yml
deleted file mode 100644
index 89c4e198..00000000
--- a/.github/workflows/book.yml
+++ /dev/null
@@ -1,33 +0,0 @@
-name: Deploy Book
-on:
-  push:
-    branches:
-      - main
-
-jobs:
-  deploy:
-    runs-on: ubuntu-latest
-    steps:
-    - uses: actions/checkout@v2
-      with:
-        fetch-depth: 0
-    - name: Install mdbook
-      run: |
-        mkdir mdbook
-        curl -sSL https://github.com/rust-lang/mdBook/releases/download/v0.4.14/mdbook-v0.4.14-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=./mdbook
-        echo `pwd`/mdbook >> $GITHUB_PATH
-    - name: Deploy GitHub Pages
-      run: |
-        cd book
-        mdbook build
-        git worktree add gh-pages gh-pages
-        git config user.name "Deploy from CI"
-        git config user.email ""
-        cd gh-pages
-        # Delete the ref to avoid keeping history.
-        git update-ref -d refs/heads/gh-pages
-        rm -rf *
-        mv ../book/* .
-        git add .
-        git commit -m "Deploy $GITHUB_SHA to gh-pages"
-        git push --force
\ No newline at end of file
diff --git a/.github/workflows/web.yml b/.github/workflows/web.yml
new file mode 100644
index 00000000..953738dd
--- /dev/null
+++ b/.github/workflows/web.yml
@@ -0,0 +1,43 @@
+name: Web
+on:
+  push:
+    branches:
+      - main
+    workflow_run:
+      workflows: ["Release"]
+      types: 
+        - completed
+
+jobs:
+  deploy:
+    runs-on: ubuntu-latest
+    steps:
+    - uses: actions/checkout@v2
+      with:
+        fetch-depth: 0
+    - uses: actions-rs/toolchain@v1
+        with:
+          toolchain: stable
+          override: true
+    - name: Install mdbook
+      run: |
+        mkdir mdbook
+        curl -sSL https://github.com/rust-lang/mdBook/releases/download/v0.4.14/mdbook-v0.4.14-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=./mdbook
+        echo `pwd`/mdbook >> $GITHUB_PATH
+    - name: Run mdbook build
+      run: |
+        cd book
+        mdbook build
+    - name: Install and run oranda
+      run: |
+        curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/oranda/releases/download/v0.0.1/oranda-v0.0.1-installer.sh | sh
+        cd cargo-dist
+        oranda build
+    - name: Deploy to gh-pages
+        uses: JamesIves/github-pages-deploy-action@v4.4.1
+        if: ${{ github.ref == 'refs/heads/main' }}
+        with:
+          branch: gh-pages
+          folder: cargo-dist/public
+          token: ${{ secrets.GITHUB_TOKEN }}
+          single-commit: true
diff --git a/.gitignore b/.gitignore
index 1cd96b3f..bf77cdd8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,5 @@
 /target
 *.snap.new
-/book/book/
\ No newline at end of file
+/book/book/
+oranda-debug.log
+cargo-dist/public
diff --git a/RELEASES.md b/CHANGELOG.md
similarity index 99%
rename from RELEASES.md
rename to CHANGELOG.md
index b59548ab..694ea13b 100644
--- a/RELEASES.md
+++ b/CHANGELOG.md
@@ -147,4 +147,4 @@ cargo-dist-schema:
 
 This is the first alpha release of cargo-dist with some minimal functionality!
 
-There are also a couple 0.0.1 prereleases that came before this one that exist to define a sort of "bootstrapping history" for the first "real" release's binary builds because I find it vaguely satisfying and you can't stop me.
\ No newline at end of file
+There are also a couple 0.0.1 prereleases that came before this one that exist to define a sort of "bootstrapping history" for the first "real" release's binary builds because I find it vaguely satisfying and you can't stop me.
diff --git a/README.md b/README.md
index b627634b..d6029207 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,12 @@
+<div class="oranda-hide">
+
 # `cargo-dist`
 
-[![crates.io](https://img.shields.io/crates/v/cargo-dist.svg)](https://crates.io/crates/cargo-dist) [![docs](https://docs.rs/cargo-dist/badge.svg)](https://docs.rs/cargo-dist)
-![Rust CI](https://github.com/axodotdev/cargo-dist/workflows/Rust%20CI/badge.svg?branch=main)
+</div>
+
+[![crates.io](https://img.shields.io/crates/v/cargo-dist.svg)](https://crates.io/crates/cargo-dist)
+[![docs](https://docs.rs/cargo-dist/badge.svg)](https://docs.rs/cargo-dist)
+[![Rust CI](https://github.com/axodotdev/cargo-dist/workflows/Rust%20CI/badge.svg?branch=main)](https://github.com/axodotdev/cargo-dist/actions/workflows/ci.yml)
 
 `cargo build` but For Building Final Distributable Artifacts and uploading them to an archive.
 
diff --git a/cargo-dist/oranda.json b/cargo-dist/oranda.json
new file mode 100644
index 00000000..d04f1796
--- /dev/null
+++ b/cargo-dist/oranda.json
@@ -0,0 +1,19 @@
+{
+  "readme_path": "../README.md",
+  "favicon": "https://www.axo.dev/favicon.ico",
+  "path_prefix": "cargo-dist",
+  "additional_pages": ["../CHANGELOG.md"],
+  "social": {
+    "image": "https://www.axo.dev/meta_small.jpeg",
+    "image_alt": "axo",
+    "twitter_account": "@axodotdev"
+  },
+  "md_book": "../book/book",
+  "artifacts": {
+    "cargo_dist": true,
+    "package_managers": {
+        "crates.io": "cargo install cargo-dist"
+    }
+  },
+  "additional_css": ["oranda/cargo-dist.css"]
+}
diff --git a/cargo-dist/oranda/cargo-dist.css b/cargo-dist/oranda/cargo-dist.css
new file mode 100644
index 00000000..8d2180bc
--- /dev/null
+++ b/cargo-dist/oranda/cargo-dist.css
@@ -0,0 +1,7 @@
+header h1 {
+    padding-bottom: 0.2em;
+}
+
+.nav ul li {
+    text-transform: uppercase;
+}


Test patch:
diff --git a/cargo-dist/tests/snapshots/cli_tests__manifest.snap b/cargo-dist/tests/snapshots/cli_tests__manifest.snap
index f159eaf5..1a6c255f 100644
--- a/cargo-dist/tests/snapshots/cli_tests__manifest.snap
+++ b/cargo-dist/tests/snapshots/cli_tests__manifest.snap
@@ -50,6 +50,11 @@ stdout:
         "x86_64-apple-darwin"
       ],
       "assets": [
+        {
+          "name": "CHANGELOG.md",
+          "path": "CHANGELOG.md",
+          "kind": "changelog"
+        },
         {
           "name": "LICENSE-APACHE",
           "path": "LICENSE-APACHE",
@@ -65,11 +70,6 @@ stdout:
           "path": "README.md",
           "kind": "readme"
         },
-        {
-          "name": "RELEASES.md",
-          "path": "RELEASES.md",
-          "kind": "changelog"
-        },
         {
           "name": "cargo-dist",
           "path": "cargo-dist",
@@ -84,6 +84,11 @@ stdout:
         "x86_64-pc-windows-msvc"
       ],
       "assets": [
+        {
+          "name": "CHANGELOG.md",
+          "path": "CHANGELOG.md",
+          "kind": "changelog"
+        },
         {
           "name": "LICENSE-APACHE",
           "path": "LICENSE-APACHE",
@@ -99,11 +104,6 @@ stdout:
           "path": "README.md",
           "kind": "readme"
         },
-        {
-          "name": "RELEASES.md",
-          "path": "RELEASES.md",
-          "kind": "changelog"
-        },
         {
           "name": "cargo-dist",
           "path": "cargo-dist.exe",
@@ -118,6 +118,11 @@ stdout:
         "x86_64-unknown-linux-gnu"
       ],
       "assets": [
+        {
+          "name": "CHANGELOG.md",
+          "path": "CHANGELOG.md",
+          "kind": "changelog"
+        },
         {
           "name": "LICENSE-APACHE",
           "path": "LICENSE-APACHE",
@@ -133,11 +138,6 @@ stdout:
           "path": "README.md",
           "kind": "readme"
         },
-        {
-          "name": "RELEASES.md",
-          "path": "RELEASES.md",
-          "kind": "changelog"
-        },
         {
           "name": "cargo-dist",
           "path": "cargo-dist",