Skip to content

Commit

Permalink
Update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
nabijaczleweli committed Jan 7, 2017
1 parent a2c70cf commit 46dbbc5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ lazy_static = "0.2"
mime_guess = "1.8"
lazysort = "0.1"
base64 = "0.2"
clap = "2.19"
clap = "2.20"
iron = "0.4"
time = "0.1"
url = "1.1"
url = "1.2"


[[bin]]
Expand Down
7 changes: 2 additions & 5 deletions src/options.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
//! ```


use clap::{AppSettings, App, Arg};
use clap::{AppSettings, Arg};
use std::path::PathBuf;
use std::env::temp_dir;
use std::str::FromStr;
Expand All @@ -36,11 +36,8 @@ pub struct Options {
impl Options {
/// Parse `env`-wide command-line arguments into an `Options` instance
pub fn parse() -> Options {
let matches = App::new("http")
.version(crate_version!())
.author(crate_authors!())
let matches = app_from_crate!()
.setting(AppSettings::ColoredHelp)
.about("Host These Things Please - a basic HTTP server for hosting a folder fast and simply")
.arg(Arg::from_usage("[DIR] 'Directory to host. Default: current working directory'")
.validator(|s| Options::filesystem_dir_validator(s, "Directory to host")))
.arg(Arg::from_usage("-p --port [port] 'Port to use. Default: first free port from 8000 up'").validator(Options::u16_validator))
Expand Down

0 comments on commit 46dbbc5

Please sign in to comment.