WIP playlist sync
This commit is contained in:
@@ -16,6 +16,10 @@ type SortCmd struct {
|
||||
Path string `arg:"positional,required"`
|
||||
}
|
||||
|
||||
type SyncPlaylists struct {
|
||||
Url string `arg:"positional,required"`
|
||||
}
|
||||
|
||||
type FixCommentCmd struct {
|
||||
Path string `arg:"positional,required"`
|
||||
}
|
||||
@@ -24,6 +28,7 @@ type args struct {
|
||||
Info *InfoCmd `arg:"subcommand:info"`
|
||||
Sort *SortCmd `arg:"subcommand:sort"`
|
||||
FixCommentTag *FixCommentCmd `arg:"subcommand:fix-comment"`
|
||||
SyncPlaylists *SyncPlaylists `arg:"subcommand:spotify"`
|
||||
Verbose bool `arg:"-v" default:"false"`
|
||||
DryRun bool `arg:"--dry-run" default:"false"`
|
||||
}
|
||||
@@ -43,6 +48,8 @@ func Run() {
|
||||
ripsort.Sort(args.Sort.Dst, args.Sort.Path)
|
||||
case args.FixCommentTag != nil:
|
||||
ripsort.FixComment(args.FixCommentTag.Path, args.DryRun)
|
||||
case args.SyncPlaylists != nil:
|
||||
ripsort.SyncPlaylists(args.SyncPlaylists.Url)
|
||||
default:
|
||||
p.Fail("Must specify command")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user