Repository: raviqqe/muffet
Pull request #115 (2020-09-27 08:50:57)

Improve help message

codecov[bot]: # [Codecov](https://codecov.io/gh/raviqqe/muffet/pull/115?src=pr&el=h1) Report
> Merging [#115](https://codecov.io/gh/raviqqe/muffet/pull/115?src=pr&el=desc) into [master](https://codecov.io/gh/raviqqe/muffet/commit/9a67319480b5d253586b0954ace0c341189d0cbf?el=desc) will **not change** coverage.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/raviqqe/muffet/pull/115/graphs/tree.svg?width=650&height=150&src=pr&token=qXJG42bGNw)](https://codecov.io/gh/raviqqe/muffet/pull/115?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master     #115   +/-   ##
=======================================
  Coverage   79.94%   79.94%           
=======================================
  Files          21       21           
  Lines         359      359           
=======================================
  Hits          287      287           
  Misses         61       61           
  Partials       11       11           
```


| [Impacted Files](https://codecov.io/gh/raviqqe/muffet/pull/115?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [arguments.go](https://codecov.io/gh/raviqqe/muffet/pull/115/diff?src=pr&el=tree#diff-YXJndW1lbnRzLmdv) | `100.00% <ø> (ø)` | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/raviqqe/muffet/pull/115?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/raviqqe/muffet/pull/115?src=pr&el=footer). Last update [9a67319...1793f8e](https://codecov.io/gh/raviqqe/muffet/pull/115?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).


Patch:
diff --git a/arguments.go b/arguments.go
index 7cff387..fadd7b9 100644
--- a/arguments.go
+++ b/arguments.go
@@ -10,16 +10,16 @@ import (
 )
 
 type arguments struct {
-	BufferSize            int      `short:"b" long:"buffer-size" default:"4096" description:"HTTP response buffer size in bytes"`
-	MaxConnections        int      `short:"c" long:"max-connections" default:"512" description:"Maximum number of HTTP connections"`
-	MaxConnectionsPerHost int      `long:"max-connections-per-host" default:"512" description:"Maximum number of HTTP connections per host"`
-	RawExcludedPatterns   []string `short:"e" long:"exclude" description:"Exclude URLs matched with given regular expressions"`
+	BufferSize            int      `short:"b" long:"buffer-size" value-name:"<size>" default:"4096" description:"HTTP response buffer size in bytes"`
+	MaxConnections        int      `short:"c" long:"max-connections" value-name:"<count>" default:"512" description:"Maximum number of HTTP connections"`
+	MaxConnectionsPerHost int      `long:"max-connections-per-host" value-name:"<count>" default:"512" description:"Maximum number of HTTP connections per host"`
+	RawExcludedPatterns   []string `short:"e" long:"exclude" value-name:"<pattern>..." description:"Exclude URLs matched with given regular expressions"`
 	FollowRobotsTxt       bool     `long:"follow-robots-txt" description:"Follow robots.txt when scraping pages"`
 	FollowSitemapXML      bool     `long:"follow-sitemap-xml" description:"Scrape only pages listed in sitemap.xml"`
-	RawHeaders            []string `long:"header" description:"Custom headers"`
+	RawHeaders            []string `long:"header" value-name:"<header>..." description:"Custom headers"`
 	IgnoreFragments       bool     `short:"f" long:"ignore-fragments" description:"Ignore URL fragments"`
-	MaxRedirections       int      `short:"r" long:"max-redirections" default:"64" description:"Maximum number of redirections"`
-	Timeout               int      `short:"t" long:"timeout" default:"10" description:"Timeout for HTTP requests in seconds"`
+	MaxRedirections       int      `short:"r" long:"max-redirections" value-name:"<count>" default:"64" description:"Maximum number of redirections"`
+	Timeout               int      `short:"t" long:"timeout" value-name:"<seconds>" default:"10" description:"Timeout for HTTP requests in seconds"`
 	Verbose               bool     `short:"v" long:"verbose" description:"Show successful results too"`
 	SkipTLSVerification   bool     `long:"skip-tls-verification" description:"Skip TLS certificate verification"`
 	OnePageOnly           bool     `long:"one-page-only" description:"Only check links found in the given URL"`
diff --git a/configuration.go b/configuration.go
index 8679357..5dd6673 100644
--- a/configuration.go
+++ b/configuration.go
@@ -3,7 +3,7 @@ package main
 import "time"
 
 const (
-	version     = "2.0.4"
+	version     = "2.0.5"
 	agentName   = "muffet"
 	concurrency = 1024
 	tcpTimeout  = time.Minute


Test patch:
diff --git a/.snapshots/TestHelp b/.snapshots/TestHelp
index 244fc99..f42f1c5 100644
--- a/.snapshots/TestHelp
+++ b/.snapshots/TestHelp
@@ -2,24 +2,28 @@ Usage:
   muffet.test [options] <url>
 
 Application Options:
-  -b, --buffer-size=              HTTP response buffer size in bytes (default:
-                                  4096)
-  -c, --max-connections=          Maximum number of HTTP connections (default:
-                                  512)
-      --max-connections-per-host= Maximum number of HTTP connections per host
-                                  (default: 512)
-  -e, --exclude=                  Exclude URLs matched with given regular
-                                  expressions
-      --follow-robots-txt         Follow robots.txt when scraping pages
-      --follow-sitemap-xml        Scrape only pages listed in sitemap.xml
-      --header=                   Custom headers
-  -f, --ignore-fragments          Ignore URL fragments
-  -r, --max-redirections=         Maximum number of redirections (default: 64)
-  -t, --timeout=                  Timeout for HTTP requests in seconds
-                                  (default: 10)
-  -v, --verbose                   Show successful results too
-      --skip-tls-verification     Skip TLS certificate verification
-      --one-page-only             Only check links found in the given URL
-  -h, --help                      Show this help
-      --version                   Show version
+  -b, --buffer-size=<size>                  HTTP response buffer size in bytes
+                                            (default: 4096)
+  -c, --max-connections=<count>             Maximum number of HTTP connections
+                                            (default: 512)
+      --max-connections-per-host=<count>    Maximum number of HTTP connections
+                                            per host (default: 512)
+  -e, --exclude=<pattern>...                Exclude URLs matched with given
+                                            regular expressions
+      --follow-robots-txt                   Follow robots.txt when scraping
+                                            pages
+      --follow-sitemap-xml                  Scrape only pages listed in
+                                            sitemap.xml
+      --header=<header>...                  Custom headers
+  -f, --ignore-fragments                    Ignore URL fragments
+  -r, --max-redirections=<count>            Maximum number of redirections
+                                            (default: 64)
+  -t, --timeout=<seconds>                   Timeout for HTTP requests in
+                                            seconds (default: 10)
+  -v, --verbose                             Show successful results too
+      --skip-tls-verification               Skip TLS certificate verification
+      --one-page-only                       Only check links found in the given
+                                            URL
+  -h, --help                                Show this help
+      --version                             Show version