#bandcamp #customization #bandcamp-downloader #bandcamp-dl

bin+lib sunny

从 Bandcamp 下载免费音乐的工具。自动将文件组织到文件夹中,ID3 标签(包括专辑封面)

5 个版本 (1 个稳定版)

1.1.0 2023 年 9 月 17 日
0.3.0 2022 年 1 月 21 日
0.2.3 2021 年 11 月 7 日
0.2.2 2021 年 11 月 7 日
0.2.0 2021 年 7 月 1 日

#4 in #bandcamp

MIT/Apache

415KB
819

欢迎使用 sunny 🌞

Version docs License: MIT

下载 Bandcamp 上免费音乐的工具。

自动将文件组织到文件夹中,ID3 标签(包括专辑封面)。

演示

Demo

动机

Sunny 极大灵感来自 SoundScrape,编写此代码的主要动机是速度和可定制性。

  • SoundScrape 是顺序下载,而 Sunny 是并行下载,大大提高了速度。
  • 曲目格式可以自定义。

格式

默认情况下,如果未传递 --path 选项,则文件将保存在当前目录中的此结构中。

Artist
  ├── Album
  │   ├── 01 - Track.mp3
  │   ├── 02 - Track.mp3
  │   ├── 03 - Track.mp3
  │   ├── 04 - Track.mp3

安装

cargo install sunny

用法

# whole discography of an artist by url
sunny https://65daysofstatic.bandcamp.com/music

# whole discography just by the name of the artist
sunny 65daysofstatic

# single album
sunny https://clevergirl.bandcamp.com/album/no-drum-and-bass-in-the-jazz-room

# single track
sunny https://65daysofstatic.bandcamp.com/track/twenty-four-twelve-twenty

# specify path to download to
sunny yvetteyoung --path=~/Music

CLI 选项

Usage: sunny [OPTIONS] <ARTIST | URL>

Arguments:
  <ARTIST | URL>
          Artist's bandcamp username or full url

Options:
  -t, --track-format <FORMAT>
          Specify track format: default is '{num} - {track}'

          available keys:
              {num} - track number
              {track} - track
              {artist} - artist
              {album} - album

          usage:
              -t='{num} - {track} - {album} {artist}'

          expands to:
              2 - Track - Album Artist

          note that `.mp3` is appended automatically.

  -p, --path <PATH>
          Directory path where downloads should be saved to.
          By default files are saved in the current directory.

  -S, --skip-albums <ALBUMS>
          Skip downloading these albums, note that albums need to be delimited by ',' eg: -s 'one,two' or --skip-albums=one,two

  -l, --list-available
          List albums/tracks available for download

  -s, --search
          Search artist, album, label, track or all, instead of downloading

  -T, --type <TYPE>
          Specify type to search for, available only for `--search` flag

          [default: artists]
          [possible values: all, artists, labels, albums, tracks]

  -h, --help
          Print help (see a summary with '-h')

  -V, --version
          Print version

      --dry-run
          Do not do anything; just show what would happen

Note: run --help to see full descriptions of each flags/options

贡献

欢迎贡献、问题和功能请求!

请参阅 TODO.md

依赖项

~23–33MB
~514K SLoC