Find method

This commit is contained in:
Dan Jones 2023-08-27 13:52:18 -05:00
commit 942d419bf6
5 changed files with 26 additions and 6 deletions

View file

@ -21,10 +21,9 @@ Cobra is a CLI library for Go that empowers applications.
This application is a tool to generate the needed files
to quickly create a Cobra application.`,
Run: func(cmd *cobra.Command, args []string) {
conn, _ := mpd.GetConn()
ret, _ := conn.Search(args...)
for _, attr := range ret {
for k, v := range attr {
ret, _ := mpd.Find(args...)
for _, song := range ret {
for k, v := range song.Attrs {
fmt.Println(k, ":", v)
}
fmt.Println("-------")