Skip to content

Commit ea9c2e9

Browse files
Show bundled libs when -b flag is used
1 parent 13fa409 commit ea9c2e9

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Diff for: commands/lib/list.go

+4-1
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,9 @@ func LibraryList(ctx context.Context, req *rpc.LibraryListRequest) (*rpc.Library
4848

4949
nameFilter := strings.ToLower(req.GetName())
5050

51-
allLibs := listLibraries(lm, req.GetUpdatable(), req.GetAll())
51+
var allLibs []*installedLib
5252
if f := req.GetFqbn(); f != "" {
53+
allLibs = listLibraries(lm, req.GetUpdatable(), true)
5354
fqbn, err := cores.ParseFQBN(req.GetFqbn())
5455
if err != nil {
5556
return nil, &arduino.InvalidFQBNError{Cause: err}
@@ -93,6 +94,8 @@ func LibraryList(ctx context.Context, req *rpc.LibraryListRequest) (*rpc.Library
9394
for _, lib := range filteredRes {
9495
allLibs = append(allLibs, lib)
9596
}
97+
} else {
98+
allLibs = listLibraries(lm, req.GetUpdatable(), req.GetAll())
9699
}
97100

98101
installedLibs := []*rpc.InstalledLibrary{}

0 commit comments

Comments
 (0)