From 7245c4179bf2999cbfecf73c08699392b9902122 Mon Sep 17 00:00:00 2001 From: fiso64 Date: Sun, 26 Mar 2023 17:35:41 +0200 Subject: [PATCH] added spotify url option --- README.md | 35 ++-- slsk-batchdl/Program.cs | 204 +++++++++++++++----- slsk-batchdl/Properties/launchSettings.json | 7 + slsk-batchdl/Spotify.cs | 101 ++++++++++ slsk-batchdl/slsk-batchdl.csproj | 2 + 5 files changed, 288 insertions(+), 61 deletions(-) create mode 100644 slsk-batchdl/Properties/launchSettings.json create mode 100644 slsk-batchdl/Spotify.cs diff --git a/README.md b/README.md index 636051c..5ede12d 100644 --- a/README.md +++ b/README.md @@ -1,15 +1,20 @@ # slsk-batchdl -A barely-functional batch downloader for Soulseek using Soulseek.NET. Accepts csv files. +A batch downloader for Soulseek using Soulseek.NET. Accepts csv files and spotify playlist urls. ``` Usage: slsk-batchdl.exe [OPTIONS] Options: - --output Downloaded files will be placed here - --csv The csv file containing track information (in case it's not in the output folder) + -p --parent Downloaded music will be placed here + -n --name Folder / playlist name. If not specified, the name of the csv file / spotify playlist is used. --username Soulseek username --password Soulseek password + --spotify Download a spotify playlist + --spotify-id Your spotify client id (in case the default one failed) + --spotify-secret Your spotify client secret (in case the default one failed) + + --csv Use a csv file containing track info to download --artist-col Specify if the csv file contains an artist name column --track-col Specify if if the csv file contains an track name column --full-title-col Specify only if there are no separate artist and track name columns in the csv @@ -17,12 +22,6 @@ Options: --length-col Specify the name of the track duration column, if exists --time-unit Time unit for the track duration column, ms or s (default: s) - --skip-existing Skip if a track matching the conditions is found in the output folder or your music library (if provided) - --music-dir Specify to also skip downloading tracks which are in your library, use with --skip-existing - --skip-if-pref-failed Skip if preferred versions of a track exist but failed to download. If no pref. versions were found, download as normal. - --create-m3u Create an m3u playlist file in the output dir - --m3u-only Only create an m3u playlist file with existing tracks and exit - --pref-format Preferred file format (default: mp3) --pref-length-tolerance Preferred length tolerance (if length col provided) (default: 3) --pref-min-bitrate Preferred minimum bitrate (default: 200) @@ -34,18 +33,28 @@ Options: --nec-max-bitrate Necessary maximum bitrate --nec-max-sample-rate Necessary maximum sample rate + --skip-existing Skip if a track matching the conditions is found in the output folder or your music library (if provided) + --music-dir Specify to also skip downloading tracks which are in your library, use with --skip-existing + --skip-if-pref-failed Skip if preferred versions of a track exist but failed to download. If no pref. versions were found, download as normal. + --create-m3u Create an m3u playlist file + --m3u-only Only create an m3u playlist file with existing tracks and exit + --m3u Where to place created m3u files (--parent by default) + --search-timeout Maximal search time (default: 15000) --download-max-stale-time