diff options
author | Sven-Hendrik Haase <svenstaro@gmail.com> | 2023-08-07 13:46:03 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-07 13:46:03 +0000 |
commit | e3c0abb309ca8b2995072e541a9b7c6a8790fe8f (patch) | |
tree | c238f73a08f05f284e36ad5ed8721d7aa3fb0c82 /src/args.rs | |
parent | Merge pull request #1192 from svenstaro/dependabot/cargo/serde-1.0.181 (diff) | |
parent | Adjust from feedback (diff) | |
download | miniserve-e3c0abb309ca8b2995072e541a9b7c6a8790fe8f.tar.gz miniserve-e3c0abb309ca8b2995072e541a9b7c6a8790fe8f.zip |
Merge pull request #1193 from nlopes/nlopes-pretty-urls
Add pretty urls
Diffstat (limited to 'src/args.rs')
-rw-r--r-- | src/args.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/args.rs b/src/args.rs index f7b42f1..590ac14 100644 --- a/src/args.rs +++ b/src/args.rs @@ -41,6 +41,14 @@ pub struct CliArgs { #[arg(long, requires = "index", env = "MINISERVE_SPA")] pub spa: bool, + /// Activate Pretty URLs mode + /// + /// This will cause the server to serve the equivalent `.html` file indicated by the path. + /// + /// `/about` will try to find `about.html` and serve it. + #[arg(long, env = "MINISERVE_PRETTY_URLS")] + pub pretty_urls: bool, + /// Port to use #[arg( short = 'p', |