-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(discovery): Begin implementing announcement
- Loading branch information
Showing
9 changed files
with
521 additions
and
77 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
[doc.extern-map.registries] | ||
crates-io = "https://docs.rs/" | ||
|
||
[target.aarch64-apple-darwin] | ||
rustflags = ["-C", "target-cpu=native", "-Z", "tune-cpu=native", "-C", "strip=symbols", "-Z", "unstable-options"] | ||
|
||
[target.x86_64-apple-darwin] | ||
rustflags = ["-C", "target-cpu=native", "-Z", "tune-cpu=native", "-C", "strip=symbols", "-Z", "unstable-options"] | ||
|
||
[target.x86_64-pc-windows-gnu] | ||
rustflags = ["-C", "link-arg=-lpsapi", "-C", "link-arg=-lbcrypt", "-C", "target-cpu=native", "-Z", "tune-cpu=native", "-C", "strip=symbols", "-Z", "unstable-options"] | ||
|
||
[target.aarch64-unknown-linux-gnu] | ||
rustflags = ["-C", "target-cpu=native", "-Z", "tune-cpu=native", "-C", "strip=symbols", "-Z", "unstable-options"] | ||
|
||
[target.x86_64-unknown-linux-gnu] | ||
rustflags = ["-C", "target-cpu=native", "-Z", "tune-cpu=native", "-C", "strip=symbols", "-Z", "unstable-options"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
name: Document and check codebase | ||
on: | ||
push: | ||
branches: [ "master" ] | ||
env: | ||
CARGO_TERM_COLOR: always | ||
jobs: | ||
build_documentation: | ||
name: Build documentation | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Setup Rust toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: nightly | ||
target: x86_64-unknown-linux-gnu | ||
default: true | ||
profile: default | ||
- name: Checkout codebase | ||
uses: actions/checkout@v4 | ||
- name: Generate documentation | ||
run: time cargo doc --no-deps -Zrustdoc-map --all-features --release --quiet | ||
- name: Fix permissions | ||
run: | | ||
chmod -c -R +rX "target/doc/" | while read line; do | ||
echo "::warning title=Invalid file permissions automatically fixed::$line" | ||
done | ||
- name: Upload Pages artifact | ||
uses: actions/upload-pages-artifact@v3 | ||
with: | ||
path: "target/doc/" | ||
deploy_documentation: | ||
needs: build_documentation | ||
name: Deploy documentation to GitHub Pages | ||
permissions: | ||
pages: write | ||
id-token: write | ||
environment: | ||
name: github-pages | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v4 | ||
apply_suggestions: | ||
name: Format code, apply compiler suggestions | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout codebase | ||
uses: actions/checkout@v4 | ||
- name: Setup Rust toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: nightly | ||
components: clippy, rustfmt | ||
profile: minimal | ||
- name: Format | ||
run: cargo fmt | ||
- name: Apply compiler suggestions | ||
run: | | ||
cargo fix --all-features --edition --edition-idioms | ||
cargo clippy --fix -Z unstable-options | ||
- name: Commit changes to code, if any | ||
run: | | ||
git config user.name github-actions | ||
git config user.email [email protected] | ||
git diff --quiet && git diff --staged --quiet || git commit -am "chore: Format and apply compiler suggestions." | ||
git push |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[toolchain] | ||
channel = "nightly" | ||
targets = [ "aarch64-unknown-linux-gnu", "x86_64-unknown-linux-gnu", "aarch64-apple-darwin", "x86_64-apple-darwin", "x86_64-pc-windows-gnu" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.