Skip to content

Commit cf728da

Browse files
authored
Merge pull request #3 from twiny/dev
code clean
2 parents f31f292 + 3dec287 commit cf728da

File tree

6 files changed

+546
-580
lines changed

6 files changed

+546
-580
lines changed

README.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,28 @@ go build -o bin/spidy -v cmd/spidy/main.go
1414
./bin/spidy -c config/config.yaml -u https://github.com
1515
```
1616

17+
## Usage
18+
19+
```sh
20+
NAME:
21+
Spidy - Domain name scraper
22+
23+
USAGE:
24+
spidy [global options] command [command options] [arguments...]
25+
26+
VERSION:
27+
2.0.0
28+
29+
COMMANDS:
30+
help, h Shows a list of commands or help for one command
31+
32+
GLOBAL OPTIONS:
33+
--config path, -c path path to config file
34+
--help, -h show help (default: false)
35+
--urls urls, -u urls urls of page to scrape (accepts multiple inputs)
36+
--version, -v print the version (default: false)
37+
```
38+
1739
## Configuration
1840

1941
```yaml

cmd/spidy/api/spider.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ import (
1313
"syscall"
1414

1515
//
16-
1716
"github.com/twiny/spidy/v2/internal/pkg/spider/v1"
1817
"github.com/twiny/spidy/v2/internal/service/cache"
1918
"github.com/twiny/spidy/v2/internal/service/writer"

internal/pkg/spider/v1/setting.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ var defaultSetting = &Setting{
4545
Interval: time.Second,
4646
},
4747
MaxBodySize: 10 * 1024 * 1024, // 10 MB
48-
UserAgents: []string{`Spidy v2 - Agent.`},
48+
UserAgents: []string{`Spidy/2.1; +https://github.com/twiny/spidy`},
4949
Proxies: []string{},
5050
},
5151
Log: struct {

0 commit comments

Comments
 (0)