Skip to content

Commit 03f4175

Browse files
committed
bump to 2.1.36
1 parent eca96f9 commit 03f4175

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

CHANGELOG

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,16 @@
11
# CHANGELOG
22

3+
- v2.1.36
4+
5+
- added `BuildFrom(structValue,opts...)` to `Creator` interface
6+
- added new example app `examples/tiny/struct`
7+
- added new builder `FromStruct` to build the command system from a struct value
8+
you can write a struct type and pass its value into FromStruct to build root
9+
command and its subcommands now.
10+
- fix `RootBuilder()` caused incorrect inCmd (-1)
11+
- fix a debug call
12+
- fix `OwnerIsNil` ...
13+
314
- v2.1.35
415

516
- improved `prompt` examples

doc.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,9 +109,14 @@
109109
// }
110110
// }
111111
//
112+
// You can build command system by kinds of forms:
113+
// - traditional stream calls (`app.Cmd("verbose", "v").Action(onVerbose)`)
114+
// - concise modes by `[Create]` and cmd/xxcmd.go
115+
// - use `[Create.FromStruct]` to build cmdsys from a struct value via `[App.FromStruct]`, see example [#example_Create_buildFromStructValue]
116+
//
112117
// Getting started from [New] or [Create] function.
113118
//
114119
// For more documentation please go and check out https://docs.hedzr.com/cmdr.v2/.
115120
package cmdr
116121

117-
const Version = "v2.1.35" // Version fir hedzr/cmdr/v2
122+
const Version = "v2.1.36" // Version fir hedzr/cmdr/v2

0 commit comments

Comments
 (0)