Skip to content

feat(cli): support getting playlists via cli #3634

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jan 9, 2025

Conversation

kgarner7
Copy link
Contributor

@kgarner7 kgarner7 commented Jan 9, 2025

No description provided.

Copy link
Member

@deluan deluan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! A couple of nits

cmd/pls.go Outdated
Run: func(cmd *cobra.Command, args []string) {
runExporter()
},
listCommand.Flags().StringVarP(&userID, "user", "u", "", "user name or ID")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be username or ID

cmd/pls.go Outdated
if outputFormat == "plain" {
println("playlist name|playlist id|owner name|owner id")
for _, playlist := range playlists {
fmt.Printf("%s|%s|%s|%s\n", playlist.Name, playlist.ID, playlist.OwnerName, playlist.OwnerID)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO, ID should come first. Also I think we should add more fields, at least Public

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feel free to add other fields as needed. The core is there though (although if more fields, csv writer might be better)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I think CSV would be better than this plain format

Copy link
Member

@deluan deluan Jan 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unless we make it more (human) readable. Then we could have the three formats

@deluan
Copy link
Member

deluan commented Jan 9, 2025

Awesome! Thanks!

@deluan deluan merged commit d60e831 into navidrome:master Jan 9, 2025
31 checks passed
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 10, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants