From bb96e2929a5a4a4a01d458b14288e9c14b83fc53 Mon Sep 17 00:00:00 2001 From: ddddddO Date: Sat, 11 Dec 2021 18:45:23 +0900 Subject: [PATCH] update readme --- README_Package_1.md | 5 +++++ README_Package_2.md | 12 +++++++++++- sample/find_pipe_programmable-gtree/main.go | 13 ++++++++++++- 3 files changed, 28 insertions(+), 2 deletions(-) diff --git a/README_Package_1.md b/README_Package_1.md index 092667b..3aba20a 100644 --- a/README_Package_1.md +++ b/README_Package_1.md @@ -84,3 +84,8 @@ func main() { } ``` + +- You can also output JSON/YAML/TOML. + - `gtree.EncodeJSON()` + - `gtree.EncodeTOML()` + - `gtree.EncodeYAML()` diff --git a/README_Package_2.md b/README_Package_2.md index c70f995..fc1a7cd 100644 --- a/README_Package_2.md +++ b/README_Package_2.md @@ -188,10 +188,14 @@ func main() { // ├── go.mod // ├── go.sum // ├── LICENSE + // ├── makefile // ├── node.go // ├── programmable.go // ├── programmable_test.go // ├── README.md + // ├── README_CLI.md + // ├── README_Package_1.md + // ├── README_Package_2.md // ├── sample // │ ├── find_pipe_programmable-gtree // │ │ └── main.go @@ -214,7 +218,13 @@ func main() { // │ └── sample6.md // ├── tmp.md // ├── tree.go - // └── tree_test.go + // ├── tree_json.go + // ├── tree_json_test.go + // ├── tree_test.go + // ├── tree_toml.go + // ├── tree_toml_test.go + // ├── tree_yaml.go + // └── tree_yaml_test.go } ``` diff --git a/sample/find_pipe_programmable-gtree/main.go b/sample/find_pipe_programmable-gtree/main.go index f152514..b2265da 100644 --- a/sample/find_pipe_programmable-gtree/main.go +++ b/sample/find_pipe_programmable-gtree/main.go @@ -37,6 +37,7 @@ func main() { if err := gtree.ExecuteProgrammably(os.Stdout, root); err != nil { panic(err) } + // Output: // . // ├── .github // │ └── workflows @@ -52,10 +53,14 @@ func main() { // ├── go.mod // ├── go.sum // ├── LICENSE + // ├── makefile // ├── node.go // ├── programmable.go // ├── programmable_test.go // ├── README.md + // ├── README_CLI.md + // ├── README_Package_1.md + // ├── README_Package_2.md // ├── sample // │ ├── find_pipe_programmable-gtree // │ │ └── main.go @@ -78,5 +83,11 @@ func main() { // │ └── sample6.md // ├── tmp.md // ├── tree.go - // └── tree_test.go + // ├── tree_json.go + // ├── tree_json_test.go + // ├── tree_test.go + // ├── tree_toml.go + // ├── tree_toml_test.go + // ├── tree_yaml.go + // └── tree_yaml_test.go }