Skip to content

Commit

Permalink
v0.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Ovyerus committed Mar 12, 2023
1 parent 27475be commit 895915e
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 17 deletions.
28 changes: 27 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,31 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to
[Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.2.0] - 2023-03-12

### Breaking Change

The previous behaviour of running the download job with the base command has
been moved into its own subcommand `run` in order to accommodate some features I
plan to add in the future.

### Added

- `--dry-run` flag to get a list of releases Bandsnatch would try to download,
without actually downloading them.
- `--debug` flag to get some extra information in certain circumstances (Might
be changed to `--verbose` in the future if I change my mind).

### Fixed

- Fix problem where some releases could crash a thread with
`` missing field `download_type` ``.

### Changed

- New `run` subcommand which replaces the previous functionality of running the
downloader on the base command.

## [0.1.1] - 2022-10-29

### Added
Expand All @@ -25,6 +50,7 @@ and this project adheres to

Initial public release of Bandsnatch.

[unreleased]: https://github.com/Ovyerus/bandsnatch/compare/v0.1.0...HEAD
[unreleased]: https://github.com/Ovyerus/bandsnatch/compare/v0.2.0...HEAD
[0.2.0]: https://github.com/Ovyerus/bandsnatch/releases/tag/v0.2.0
[0.1.1]: https://github.com/Ovyerus/bandsnatch/releases/tag/v0.1.1
[0.1.0]: https://github.com/Ovyerus/bandsnatch/releases/tag/v0.1.0
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "bandsnatch"
version = "0.1.1"
version = "0.2.0"
edition = "2021"
description = "A CLI batch downloader for your Bandcamp collection"
authors = ["Michael Mitchell <[email protected]>"]
Expand Down
31 changes: 17 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,42 +26,43 @@ project in general I'd love to hear them.

## Usage

The most basic usage is along the lines of `bandsnatch -f <format> <username>`,
as it will try to automatically fetch cookies from a local `cookies.json` or
from Firefox (TODO). But if this fails you can provide the `-c` option with a
path to a cookies file to use.
The most basic usage is along the lines of
`bandsnatch run -f <format> <username>`, as it will try to automatically fetch
cookies from a local `cookies.json` or from Firefox (TODO). But if this fails
you can provide the `-c` option with a path to a cookies file to use.

For more advanced usage, you can run `bandsnatch -h` to get output similar to
the following.
For more advanced usage, you can run `bandsnatch run -h` to get output similar
to the following.

```
A CLI batch downloader for your Bandcamp collection
Run Bandsnatch to download your collection
Usage: bandsnatch [OPTIONS] --format <AUDIO_FORMAT> <USER>
Usage: bandsnatch run [OPTIONS] --format <AUDIO_FORMAT> <USER>
Arguments:
<USER> Name of the user to download releases from (must be logged in through cookies) [env: BS_USER=]
Options:
-f, --format <AUDIO_FORMAT> The audio format to download the files in [env: BS_FORMAT=] [possible values: flac, wav, aac-hi, mp3-320, aiff-lossless, vorbis, mp3-v0, alac]
-c, --cookies <COOKIES_FILE> [env: BS_COOKIES=]
--debug Enables some extra debug output in certain scenarios [env: BS_DEBUG=]
-d, --dry-run Return a list of all tracks to be downloaded, without actually downloading them
-F, --force Ignores any found cache file and instead does a from-scratch download run [env: BS_FORCE=]
-j, --jobs <JOBS> The amount of parallel jobs (threads) to use [env: BS_JOBS=] [default: 4]
-n, --limit <LIMIT> Maximum number of releases to download. Useful for testing [env: BS_LIMIT=]
-o, --output-folder <FOLDER> The folder to extract downloaded releases to [env: BS_OUTPUT_FOLDER=] [default: ./]
-h, --help Print help information
-V, --version Print version information
```

Besides these options, you can also use environment variables with the option
name in `SCREAMING_SNAKE_CASE`, prefixed with `BS_`, so that if set up correctly
you can just run `bandsnatch` and have it automatically download your collection
to the folder you want.
you can just run `bandsnatch run` and have it automatically download your
collection to the folder you want.

### Exmaple

```
bandsnatch -c ./cookies.json -f flac -o ./Music ovyerus
bandsnatch run -c ./cookies.json -f flac -o ./Music ovyerus
```

This would download my entire music collection into a local "Music" folder, and
Expand All @@ -81,9 +82,11 @@ to extract the cookies in the Netscape format, which Bandsnatch also supports.

If you don't provide the `--cookies` option, Bandsnatch will attempt to
automatically find a file named `cookies.json` or `cookies.txt` in the local
directory and load it. Failing that, if you use Firefox on Windows or Linux,
directory and load it.

<!-- Failing that, if you use Firefox on Windows or Linux,
bandsnatch will try to automatically load the cookies from there if possible
(TODO).
(TODO). -->

## Installing

Expand Down

0 comments on commit 895915e

Please sign in to comment.