From fd5c13f7ed2e9a3e3a82fa6a4c6ffe649f3f32f2 Mon Sep 17 00:00:00 2001 From: Eyal Posener Date: Sun, 7 May 2017 07:59:42 +0300 Subject: Remove Name from Command struct --- readme.md | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'readme.md') diff --git a/readme.md b/readme.md index 62ce6af..5ad2e71 100644 --- a/readme.md +++ b/readme.md @@ -54,9 +54,6 @@ func main() { // to complete. run := complete.Command{ - // Name must be exactly as the binary that we want to complete - Name: "run", - // Sub defines a list of sub commands of the program, // this is recursive, since every command is of type command also. Sub: complete.Commands{ @@ -88,6 +85,7 @@ func main() { // run the command completion, as part of the main() function. // this triggers the autocompletion when needed. - complete.Run(run) + // name must be exactly as the binary that we want to complete. + complete.Run("run", run) } ``` -- cgit v1.2.3