-
-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #45 from logankaser/master
Update Binserve Dependencies
- Loading branch information
Showing
13 changed files
with
318 additions
and
360 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
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 |
---|---|---|
@@ -1,18 +1,14 @@ | ||
use clap::{Command, Arg, ArgMatches}; | ||
|
||
use crate::core::VERSION; | ||
use clap::{Arg, ArgMatches, Command}; | ||
|
||
/// Prints an ASCII art banner to look cool! | ||
pub fn banner() { | ||
eprintln!( | ||
"{}", format!("{} {}\n", include_str!("banner"), VERSION) | ||
) | ||
eprintln!("{} {}\n", include_str!("banner"), env!("CARGO_PKG_VERSION")) | ||
} | ||
|
||
/// Command-line arguments | ||
pub fn args() -> ArgMatches { | ||
Command::new("binserve") | ||
.version(VERSION) | ||
.version(env!("CARGO_PKG_VERSION")) | ||
.author("Mufeed VH <[email protected]>") | ||
.about("A fast static web server with Automatic HTTPs, routing, templating, and security in a single binary you can setup with zero code.") | ||
.arg(Arg::new("command") | ||
|
@@ -25,21 +21,18 @@ pub fn args() -> ArgMatches { | |
.long("host") | ||
.value_name("HOST IP/DOMAIN:PORT") | ||
.help("Host to run binserve on.") | ||
.required(false) | ||
.takes_value(true)) | ||
.required(false)) | ||
.arg(Arg::new("tls_key") | ||
.short('k') | ||
.long("key") | ||
.value_name("TLS KEY") | ||
.help("TLS key file.") | ||
.required(false) | ||
.takes_value(true)) | ||
.required(false)) | ||
.arg(Arg::new("tls_cert") | ||
.short('c') | ||
.long("cert") | ||
.value_name("TLS CERT") | ||
.help("TLS cert file.") | ||
.required(false) | ||
.takes_value(true)) | ||
.required(false)) | ||
.get_matches() | ||
} | ||
} |
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 |
---|---|---|
@@ -1,2 +1,2 @@ | ||
pub(crate) mod interface; | ||
pub(crate) mod messages; | ||
pub(crate) mod messages; |
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.