Skip to content

Commit

Permalink
refactor(list): sorting the output of the list cmd
Browse files Browse the repository at this point in the history
  • Loading branch information
summingyu committed Apr 9, 2022
1 parent 4416a7d commit 1e86050
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cmd/devstream/list/list.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package list

import (
"fmt"
"sort"
"strings"
)

Expand All @@ -15,6 +16,7 @@ var PluginsName string
// List all of plugins name
func List() {
listPluginsName := strings.Fields(PluginsName)
sort.Strings(listPluginsName)
for _, pluginName := range listPluginsName {
fmt.Println(pluginName)
}
Expand Down

0 comments on commit 1e86050

Please sign in to comment.