diff --git a/packages/perseus-actix-web/src/lib.rs b/packages/perseus-actix-web/src/lib.rs index e63be06eea..2014605c83 100644 --- a/packages/perseus-actix-web/src/lib.rs +++ b/packages/perseus-actix-web/src/lib.rs @@ -1,6 +1,6 @@ /*! * Perseus is a blazingly fast frontend web development framework built in Rust with support for major rendering strategies, - * reactivity without a virtual DOM, and extreme customizability. It wraps the lower-level capabilities of[Sycamore](https://github.com/sycamore-rs/sycamore) + * reactivity without a virtual DOM, and extreme customizability. It wraps the lower-level capabilities of [Sycamore](https://github.com/sycamore-rs/sycamore) * and provides a NextJS-like API! * * - ✨ Supports static generation (serving only static resources) @@ -11,7 +11,7 @@ * - ✨ CLI harness that lets you build apps with ease and confidence * * This is the documentation for the Perseus Actix Web integration, but there's also [a CLI](https://arctic-hen7.github.io/perseus/cli.html), - * [the core package](https://crates.io/crates/perseus), and other integrations [integrations](https://arctic-hen7.github.io/perseus/serving.html) + * [the core package](https://crates.io/crates/perseus), and other [integrations](https://arctic-hen7.github.io/perseus/serving.html) * to make serving apps on other platforms easier! * * # Resources diff --git a/packages/perseus-cli/Cargo.toml b/packages/perseus-cli/Cargo.toml index 66d749b365..71c88c084d 100644 --- a/packages/perseus-cli/Cargo.toml +++ b/packages/perseus-cli/Cargo.toml @@ -7,7 +7,7 @@ authors = ["arctic_hen7 "] license = "MIT" repository = "https://github.com/arctic-hen7/perseus" homepage = "https://arctic-hen7.github.io/perseus" -readme = "../../README.md" +readme = "./README.md" keywords = ["wasm", "cli", "webdev", "ssg", "ssr"] categories = ["wasm", "development-tools", "asynchronous", "gui", "command-line-utilities"] include = [ @@ -28,7 +28,7 @@ serde = "1" serde_json = "1" [lib] -name = "lib" +name = "perseus_cli" [[bin]] name = "perseus" diff --git a/packages/perseus-cli/README.md b/packages/perseus-cli/README.md new file mode 100644 index 0000000000..ccb1d9b8b0 --- /dev/null +++ b/packages/perseus-cli/README.md @@ -0,0 +1,11 @@ +# Perseus CLI + +This is the official [Perseus](https://github.com/arctic-hen7/perseus) CLI for making building and sevring apps significantly easier! You can install it like so: + +``` +cargo install perseus-cli +``` + +And you'll then have an executable called `perseus` on your system! + +If you're new to Perseus, you should check out [the core package](https://github.com/arctic-hen7/perseus) first. diff --git a/packages/perseus-cli/src/bin/main.rs b/packages/perseus-cli/src/bin/main.rs index 38f6ad1fe1..690698046e 100644 --- a/packages/perseus-cli/src/bin/main.rs +++ b/packages/perseus-cli/src/bin/main.rs @@ -1,5 +1,5 @@ -use lib::errors::*; -use lib::{build, check_env, delete_bad_dir, help, prepare, serve, PERSEUS_VERSION}; +use perseus_cli::errors::*; +use perseus_cli::{build, check_env, delete_bad_dir, help, prepare, serve, PERSEUS_VERSION}; use std::env; use std::io::Write; use std::path::PathBuf; diff --git a/packages/perseus-cli/src/help.rs b/packages/perseus-cli/src/help.rs index 2580d14455..a651498f14 100644 --- a/packages/perseus-cli/src/help.rs +++ b/packages/perseus-cli/src/help.rs @@ -1,5 +1,6 @@ use crate::PERSEUS_VERSION; +/// Prints the help page. pub fn help(output: &mut impl std::io::Write) { writeln!( output, diff --git a/packages/perseus-cli/src/lib.rs b/packages/perseus-cli/src/lib.rs index 6cd18e1e6d..9c1cafab00 100644 --- a/packages/perseus-cli/src/lib.rs +++ b/packages/perseus-cli/src/lib.rs @@ -1,3 +1,32 @@ +/*! + * Perseus is a blazingly fast frontend web development framework built in Rust with support for major rendering strategies, + * reactivity without a virtual DOM, and extreme customizability. It wraps the lower-level capabilities of[Sycamore](https://github.com/sycamore-rs/sycamore) + * and provides a NextJS-like API! + * + * - ✨ Supports static generation (serving only static resources) + * - ✨ Supports server-side rendering (serving dynamic resources) + * - ✨ Supports revalidation after time and/or with custom logic (updating rendered pages) + * - ✨ Supports incremental regeneration (build on demand) + * - ✨ Open build matrix (use any rendering strategy with anything else, mostly) + * - ✨ CLI harness that lets you build apps with ease and confidence + * + * This is the documentation for the Perseus CLI, but there's also [the core package](https://crates.io/crates/perseus) and [integrations](https://arctic-hen7.github.io/perseus/serving.html) + * to make serving apps on other platforms easier! + * + * # Resources + * + * These docs will help you as a reference, but [the book](https://arctic-hen7.github.io/perseus/cli.html) should + * be your first port of call for learning about how to use Perseus and how it works. + * + * - [The Book](https://arctic-hen7.github.io/perseus) + * - [GitHub repository](https://github.com/arctic-hen7/perseus) + * - [Crate page](https://crates.io/crates/perseus) + * - [Gitter chat](https://gitter.im/perseus-framework/community) + * - [Discord server channel](https://discord.com/channels/820400041332179004/883168134331256892) (for Sycamore-related stuff) + */ + +#![deny(missing_docs)] + mod build; mod cmd; pub mod errors; @@ -11,6 +40,7 @@ use errors::*; use std::fs; use std::path::PathBuf; +/// The current version of the CLI, extracted from the crate version. pub const PERSEUS_VERSION: &str = env!("CARGO_PKG_VERSION"); pub use build::build; pub use help::help; diff --git a/packages/perseus/src/lib.rs b/packages/perseus/src/lib.rs index 7f82b25ba0..a98a63de19 100644 --- a/packages/perseus/src/lib.rs +++ b/packages/perseus/src/lib.rs @@ -1,6 +1,6 @@ /*! * Perseus is a blazingly fast frontend web development framework built in Rust with support for major rendering strategies, - * reactivity without a virtual DOM, and extreme customizability. It wraps the lower-level capabilities of[Sycamore](https://github.com/sycamore-rs/sycamore) + * reactivity without a virtual DOM, and extreme customizability. It wraps the lower-level capabilities of [Sycamore](https://github.com/sycamore-rs/sycamore) * and provides a NextJS-like API! * * - ✨ Supports static generation (serving only static resources)