Restore docs CI checks and fix all doc lints (#4204)

This commit is contained in:
Evan Almloff authored and GitHub committed 2025-05-26 19:50:51 +01:00
1 parent 9027ffc278
commit ee3b45af49
57 files changed
+120 -130

No files matched your search

+1 -1
View File
@@ -1140,7 +1140,7 @@ We checked the folder: {}
/// - If the app fails to launch, errors are logged for debugging purposes.
///
/// # Resources:
/// - https://developer.android.com/studio/run/emulator-commandline
/// - <https://developer.android.com/studio/run/emulator-commandline>
async fn open_android_sim(
&self,
root: bool,
+2 -2
View File
@@ -415,7 +415,7 @@ fn create_native_jump_table(
/// It doesn't seem like we can compile the base module to export these, sadly, so we're going
/// to manually satisfy them here, removing their need to be imported.
///
/// https://github.com/WebAssembly/tool-conventions/blob/main/DynamicLinking.md
/// <https://github.com/WebAssembly/tool-conventions/blob/main/DynamicLinking.md>
fn create_wasm_jump_table(patch: &Path, cache: &HotpatchModuleCache) -> Result<JumpTable> {
let name_to_ifunc_old = &cache.symbol_ifunc_map;
let old = &cache.old_wasm;
@@ -1299,7 +1299,7 @@ pub fn prepare_wasm_base_module(bytes: &[u8]) -> Result<Vec<u8>> {
///
/// Uses the heuristics from the wasm-bindgen source code itself:
///
/// https://github.com/rustwasm/wasm-bindgen/blob/c35cc9369d5e0dc418986f7811a0dd702fb33ef9/crates/cli-support/src/wit/mod.rs#L1165
/// <https://github.com/rustwasm/wasm-bindgen/blob/c35cc9369d5e0dc418986f7811a0dd702fb33ef9/crates/cli-support/src/wit/mod.rs#L1165>
fn name_is_bindgen_symbol(name: &str) -> bool {
name.contains("__wbindgen_describe")
|| name.contains("__wbindgen_externref")
+5 -5
View File
@@ -55,7 +55,7 @@
//!
//! Currently, we defer most of our deploy-based bundling to Tauri bundle, though we should migrate
//! to just bundling everything ourselves. This would require us to implement code-signing which
//! is a bit of a pain, but fortunately a solved process (https://github.com/rust-mobile/xbuild).
//! is a bit of a pain, but fortunately a solved process (<https://github.com/rust-mobile/xbuild>).
//!
//! ## Build Structure
//!
@@ -107,7 +107,7 @@
//!
//! ### Linux:
//!
//! https://docs.appimage.org/reference/appdir.html#ref-appdir
//! <https://docs.appimage.org/reference/appdir.html#ref-appdir>
//! current_exe.join("Assets")
//! ```
//! app.appimage/
@@ -157,7 +157,7 @@
//! drive the kotlin build ourselves. This would let us drop gradle (yay! no plugins!) but requires
//! us to manage dependencies (like kotlinc) ourselves (yuck!).
//!
//! https://github.com/WanghongLin/miscellaneous/blob/master/tools/build-apk-manually.sh
//! <https://github.com/WanghongLin/miscellaneous/blob/master/tools/build-apk-manually.sh>
//!
//! Unfortunately, it seems that while we can drop the `android` build plugin, we still will need
//! gradle since kotlin is basically gradle-only.
@@ -309,8 +309,8 @@
//! The idea here is that we can run any of the programs in the same way that they're deployed.
//!
//! ## Bundle structure links
//! - apple: <https>://developer.apple.com/documentation/bundleresources/placing_content_in_a_bundle>
//! - appimage: <https>://docs.appimage.org/packaging-guide/manual.html#ref-manual>
//! - apple: <https://developer.apple.com/documentation/bundleresources/placing_content_in_a_bundle>
//! - appimage: <https://docs.appimage.org/packaging-guide/manual.html#ref-manual>
//!
//! ## Extra links
//! - xbuild: <https://github.com/rust-mobile/xbuild/blob/master/xbuild/src/command/build.rs>
+1 -1
View File
@@ -8,7 +8,7 @@ use tokio::process::Command;
/// The tools for Android (ndk, sdk, etc)
///
/// https://gist.github.com/Pulimet/5013acf2cd5b28e55036c82c91bd56d8?permalink_comment_id=3678614
/// <https://gist.github.com/Pulimet/5013acf2cd5b28e55036c82c91bd56d8?permalink_comment_id=3678614>
#[derive(Debug, Clone)]
pub(crate) struct AndroidTools {
pub(crate) sdk: Option<PathBuf>,
+1 -1
View File
@@ -43,7 +43,7 @@ pub struct BuildArgs {
///
/// Server and Client are special targets that integrate with `dx serve`, while `crate` is a generic.
///
/// ```
/// ```sh
/// dx serve \
/// client --target aarch64-apple-darwin \
/// server --target wasm32-unknown-unknown \
+1 -1
View File
@@ -1,7 +1,7 @@
//! Run linting against the user's codebase.
//!
//! For reference, the rustfmt main.rs file
//! https://github.com/rust-lang/rustfmt/blob/master/src/bin/main.rs
//! <https://github.com/rust-lang/rustfmt/blob/master/src/bin/main.rs>
use super::*;
use crate::BuildRequest;
+2 -2
View File
@@ -38,7 +38,7 @@ pub struct Create {
#[clap(long)]
subtemplate: Option<String>,
/// Pass <option>=<value> for the used template (e.g., `foo=bar`)
/// Pass `<option>=<value>` for the used template (e.g., `foo=bar`)
#[clap(short, long)]
option: Vec<String>,
@@ -119,7 +119,7 @@ pub(crate) fn resolve_template_and_branch(
/// Prevent hidden cursor if Ctrl+C is pressed when interacting
/// with cargo-generate's prompts.
///
/// See https://github.com/DioxusLabs/dioxus/pull/2603.
/// See <https://github.com/DioxusLabs/dioxus/pull/2603>.
pub(crate) fn restore_cursor_on_sigint() {
ctrlc::set_handler(move || {
if let Err(err) = console::Term::stdout().show_cursor() {
+1 -1
View File
@@ -35,7 +35,7 @@ pub struct Init {
#[clap(long)]
subtemplate: Option<String>,
/// Pass <option>=<value> for the used template (e.g., `foo=bar`)
/// Pass `<option>=<value>` for the used template (e.g., `foo=bar`)
#[clap(short, long)]
option: Vec<String>,
+1 -1
View File
@@ -38,7 +38,7 @@ pub struct LinkAction {
/// The linker flavor to use. This influences the argument style that gets passed to the linker.
/// We're imitating the rustc linker flavors here.
///
/// https://doc.rust-lang.org/beta/nightly-rustc/rustc_target/spec/enum.LinkerFlavor.html
/// <https://doc.rust-lang.org/beta/nightly-rustc/rustc_target/spec/enum.LinkerFlavor.html>
#[derive(Debug, Serialize, Deserialize, PartialEq, Clone)]
pub enum LinkerFlavor {
Gnu,
+3 -8
View File
@@ -8,25 +8,20 @@ use std::{backtrace::Backtrace, panic::AssertUnwindSafe};
///
/// `dx serve` takes cargo args by default, except with a required `--platform` arg:
///
/// ```
/// ```sh
/// dx serve --example blah --target blah --platform android
/// ```
///
/// A simple serve:
/// ```
/// ```sh
/// dx serve --platform web
/// ```
///
/// A serve with customized arguments:
///
/// ```
/// ```
///
/// As of dioxus 0.7, `dx serve` allows independent customization of the client and server builds,
/// allowing workspaces and removing any "magic" done to support ergonomic fullstack serving with
/// an plain `dx serve`. These require specifying more arguments like features since they won't be autodetected.
///
/// ```
/// ```sh
/// dx serve \
/// client --package frontend \
/// server --package backend
+1 -1
View File
@@ -80,7 +80,7 @@ pub(crate) struct WixSettings {
pub(crate) fips_compliant: bool,
/// MSI installer version in the format `major.minor.patch.build` (build is optional).
///
/// Because a valid version is required for MSI installer, it will be derived from [`PackageSettings::version`] if this field is not set.
/// Because a valid version is required for MSI installer, it will be derived from [`tauri_bundler::PackageSettings::version`] if this field is not set.
///
/// The first field is the major version and has a maximum value of 255. The second field is the minor version and has a maximum value of 255.
/// The third and fourth fields have a maximum value of 65,535.
+1 -1
View File
@@ -30,7 +30,7 @@ pub struct RustcArgs {
/// Run rustc directly, but output the result to a file.
///
/// https://doc.rust-lang.org/cargo/reference/config.html#buildrustc
/// <https://doc.rust-lang.org/cargo/reference/config.html#buildrustc>
pub async fn run_rustc() {
// if we happen to be both a rustc wrapper and a linker, we want to run the linker if the arguments seem linker-y
// this is a stupid hack
+1 -1
View File
@@ -3,7 +3,7 @@ use std::fmt::{self, Display, Formatter};
/// A buffer that can be rendered to and then dumped as raw ansi codes
///
/// This is taken from a PR on the ratatui repo (https://github.com/ratatui/ratatui/pull/1065) and
/// This is taken from a PR on the ratatui repo (<https://github.com/ratatui/ratatui/pull/1065>) and
/// modified to be more appropriate for our use case.
pub struct AnsiStringLine {
buf: Buffer,
+3 -3
View File
@@ -773,7 +773,7 @@ impl AppServer {
/// we mostly just care about workspace files and local dependencies.
///
/// Dep-info file background:
/// https://doc.rust-lang.org/stable/nightly-rustc/cargo/core/compiler/fingerprint/index.html#dep-info-files
/// <https://doc.rust-lang.org/stable/nightly-rustc/cargo/core/compiler/fingerprint/index.html#dep-info-files>
fn load_rsx_filemap(&mut self) {
self.fill_filemap_from_krate(self.client.build.crate_dir());
@@ -1109,9 +1109,9 @@ fn handle_notify_error(err: notify::Error) {
/// Detects if `dx` is being ran in a WSL environment.
///
/// We determine this based on whether the keyword `microsoft` or `wsl` is contained within the [`WSL_1`] or [`WSL_2`] files.
/// We determine this based on whether the keyword `microsoft` or `wsl` is contained within the `WSL_1` or `WSL_2` files.
/// This may fail in the future as it isn't guaranteed by Microsoft.
/// See https://github.com/microsoft/WSL/issues/423#issuecomment-221627364
/// See <https://github.com/microsoft/WSL/issues/423#issuecomment-221627364>
fn is_wsl() -> bool {
const WSL_1: &str = "/proc/sys/kernel/osrelease";
const WSL_2: &str = "/proc/version";