Skip to content

Commit

Permalink
Better Usage
Browse files Browse the repository at this point in the history
  • Loading branch information
liesauer committed Apr 10, 2020
1 parent 70c00ad commit 05e4564
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 12 deletions.
18 changes: 10 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,14 +93,16 @@ when you run `dotnet publish -r` (only works with `SCD` mode), everything is don
2. Use the binary application if your project has already be published.
```
Usage:
ncbeauty [--<force=True|False>] [--<gitcdn>] [--<gittree>] [--<loglevel=Error|Detail|Info>] [--<nopatch=True|False>] <beautyDir> [<libsDir>] [<excludes>=dll1.dll;lib*;...]
ncbeauty [--<loglevel=Error|Detail|Info>] setcdn <gitcdn>
ncbeauty [--<loglevel=Error|Detail|Info>] getcdn
ncbeauty [--<loglevel=Error|Detail|Info>] delcdn
ncbeauty [--force=(True|False)] [--gitcdn=<gitcdn>] [--gittree=<gittree>] [--loglevel=(Error|Detail|Info)] [--nopatch=(True|False)] <beautyDir> [<libsDir> [<excludes>]]
Setting GitCDN:
ncbeauty [--loglevel=(Error|Detail|Info)] setcdn <gitcdn>
ncbeauty [--loglevel=(Error|Detail|Info)] getcdn
ncbeauty [--loglevel=(Error|Detail|Info)] delcdn
```
for example
```
ncbeauty /path/to/publishDir
ncbeauty /path/to/publishDir libraries "dll1.dll;lib*;..."
```

3. Install .NETCore Global Tool
Expand All @@ -119,11 +121,11 @@ https://gitee.com/liesauer/HostFXRPatcher
`ncbeauty` [1.2.1](https://github.com/nulastudio/NetCoreBeauty/releases/tag/v1.2.1) supports setting default Git CDN now, you don't need `--gitcdn` all the time if you are using binary distribution. but how ever default git cdn can be override by `--gitcdn`.
Usage:
```
ncbeauty [--<loglevel=Error|Detail|Info>] setcdn <gitcdn>
ncbeauty [--loglevel=(Error|Detail|Info)] setcdn <gitcdn>
set current default git cdn, can be override by --gitcdn.
ncbeauty [--<loglevel=Error|Detail|Info>] getcdn
ncbeauty [--loglevel=(Error|Detail|Info)] getcdn
print current default git cdn.
ncbeauty [--<loglevel=Error|Detail|Info>] delcdn
ncbeauty [--loglevel=(Error|Detail|Info)] delcdn
remove current default git cdn, after removed, use --gitcdn to specify.
```

Expand Down
15 changes: 11 additions & 4 deletions src/main/beauty.go
Original file line number Diff line number Diff line change
Expand Up @@ -239,13 +239,20 @@ func checkArgumentsCount(excepted int, got int) bool {

func usage() {
fmt.Println("Usage:")
fmt.Println("ncbeauty [--<force=True|False>] [--<gitcdn>] [--<gittree>] [--<loglevel=Error|Detail|Info>] [--<nopatch=True|False>] <beautyDir> [<libsDir>] [<excludes>=dll1.dll;lib*;...]")
fmt.Println("ncbeauty [--force=(True|False)] [--gitcdn=<gitcdn>] [--gittree=<gittree>] [--loglevel=(Error|Detail|Info)] [--nopatch=(True|False)] <beautyDir> [<libsDir> [<excludes>]]")
fmt.Println("")
fmt.Println("Arguments")
fmt.Println(" <excludes> dlls that no need to be moved, multi-dlls separated with \";\". Example: dll1.dll;lib*;...")
fmt.Println("")
fmt.Println("Options")
flag.PrintDefaults()
fmt.Println("ncbeauty [--<loglevel=Error|Detail|Info>] setcdn <gitcdn>")
fmt.Println("")
fmt.Println("Setting GitCDN")
fmt.Println("ncbeauty [--loglevel=(Error|Detail|Info)] setcdn <gitcdn>")
fmt.Println(" set current default git cdn, can be override by --gitcdn.")
fmt.Println("ncbeauty [--<loglevel=Error|Detail|Info>] getcdn")
fmt.Println("ncbeauty [--loglevel=(Error|Detail|Info)] getcdn")
fmt.Println(" print current default git cdn.")
fmt.Println("ncbeauty [--<loglevel=Error|Detail|Info>] delcdn")
fmt.Println("ncbeauty [--loglevel=(Error|Detail|Info)] delcdn")
fmt.Println(" remove current default git cdn, after removed, use --gitcdn to specify.")
}

Expand Down

0 comments on commit 05e4564

Please sign in to comment.