@@ -45,7 +45,9 @@ not listed, they can be listed by adding the --all flag.`),
45
45
Example : " " + os .Args [0 ] + " lib list" ,
46
46
Args : cobra .MaximumNArgs (1 ),
47
47
Run : func (cmd * cobra.Command , args []string ) {
48
- runListCommand (args , all , updatable )
48
+ instance := instance .CreateAndInit ()
49
+ logrus .Info ("Executing `arduino-cli lib list`" )
50
+ List (instance , args , all , updatable )
49
51
},
50
52
}
51
53
listCommand .Flags ().BoolVar (& all , "all" , false , tr ("Include built-in libraries (from platforms and IDE) in listing." ))
@@ -54,12 +56,6 @@ not listed, they can be listed by adding the --all flag.`),
54
56
return listCommand
55
57
}
56
58
57
- func runListCommand (args []string , all bool , updatable bool ) {
58
- instance := instance .CreateAndInit ()
59
- logrus .Info ("Executing `arduino-cli lib list`" )
60
- List (instance , args , all , updatable )
61
- }
62
-
63
59
// List gets and prints a list of installed libraries.
64
60
func List (instance * rpc.Instance , args []string , all bool , updatable bool ) {
65
61
installedLibs := GetList (instance , args , all , updatable )
0 commit comments