Skip to content

Commit

Permalink
auto bind server node flags
Browse files Browse the repository at this point in the history
  • Loading branch information
mars315 committed Jan 4, 2024
1 parent a02eb30 commit f900899
Show file tree
Hide file tree
Showing 3 changed files with 157 additions and 206 deletions.
10 changes: 7 additions & 3 deletions example/full/cmd.go
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
// `go run cmd.go --a2.f2 "KK"`
// `go run cmd.go --f2 "KK"`
// output:
//
// {
// "F1": "x86xm",
// "F2": "KK",
// "F3": 87,
// "A4": {
// "F4": 99
// },
// "DBUrl": ":27071",
// "LogFile": "stdout",
// "Debug": true,
Expand All @@ -18,20 +20,22 @@
//
// `go run cmd.go -h`
// output:
//
// Flags:
// --a3.f3 int f3 (default 87)
// --age int age (default 18)
// --c.f1 string f1 (default "x86xm")
// --dburl string dburl (default ":27071")
// --debug enable debug model,false to disable; ,please (default true)
// --f2 string f2 (default "ZH")
// --f4 int f4 (default 99)
// -h, --help help for test
// --keep duration (default 1s)
// --logfile string udp|udp:UdpAddr|FilePath|redirect:x (default "stdout")
// --name string name (default "test")
// --short string short (default "s")
// --usage string usage (default "usage")
//

package main

import (
Expand Down
Loading

0 comments on commit f900899

Please sign in to comment.