add CLI parity flags and expand provider support

This brings the Go CLI closer to upstream behavior with global flag handling and clearer resolve failures, while adding Tidal video downloads plus initial Deezer and SoundCloud no-account flows for broader end-to-end coverage.
This commit is contained in:
2026-04-20 00:56:10 +02:00
parent 4da5114a70
commit b2688ce949
15 changed files with 1746 additions and 57 deletions

View File

@@ -65,7 +65,7 @@ func Prepare(ctx context.Context, dl Downloader, folder string, albumMeta map[st
}
if cfg.Embed && embedURL != "" {
embedDir := filepath.Join(folder, "__artwork")
embedDir := sessionEmbedDir(folder)
if err := os.MkdirAll(embedDir, 0o755); err == nil {
registerTempDir(embedDir)
embedPath := filepath.Join(embedDir, embedFilename(embedURL))
@@ -134,6 +134,11 @@ func embedFilename(url string) string {
return fmt.Sprintf("cover%x.jpg", s[:8])
}
func sessionEmbedDir(folder string) string {
key := sha1.Sum([]byte(folder))
return filepath.Join(os.TempDir(), "streamrip-go-artwork", fmt.Sprintf("%x", key[:8]))
}
func stringAny(v any) string {
s, _ := v.(string)
return s