Update readme instructions and update workflow

This commit is contained in:
oSumAtrIX 2021-10-17 09:00:16 +02:00
parent 3148032089
commit 79d3d1bc5e
No known key found for this signature in database
GPG key ID: A9B3094ACDB604B4
3 changed files with 29 additions and 6 deletions

View file

@ -1,4 +1,5 @@
on:
workflow_dispatch:
push:
paths:
- 'src/**'
@ -10,6 +11,7 @@ name: "Build project"
env:
CARGO_TERM_COLOR: always
CARGO_NET_GIT_FETCH_WITH_CLI: true
jobs:
build_and_test:
@ -19,6 +21,9 @@ jobs:
steps:
- uses: actions/checkout@v2
- run: sudo apt install -y libasound2-dev libmp3lame-dev
- uses: webfactory/ssh-agent@v0.5.3
with:
ssh-private-key: ${{ secrets.FREE_LIBRESPOT_PRIVATE_KEY }}
- uses: actions-rs/toolchain@v1
with:
override: true

View file

@ -31,7 +31,7 @@ reqwest = "0.11"
colored = "2"
lame = "0.1.3"
aspotify = "0.7"
librespot = { git = "https://github.com/oSumAtrIX/free-librespot" }
librespot = { git = "ssh://git@github.com/oSumAtrIX/free-librespot.git", branch = "dev" }
async-std = { version = "1.10", features = ["attributes", "tokio1"] }
serde_json = "1.0"
async-stream = "0.3"

View file

@ -18,8 +18,8 @@ I am not responsible in any way for the usage of the source code.
## Features
- Free account support (if using free-librespot fork)
- Download 96kbit/s, 160kbit/s, 256kbit/s audio with a free and 320 kbit/s audio with a premium account from spotify, directly
- Use free Spotify accounts (if using free-librespot fork)
- Download 96k, 160, 256kbit/s audio with a free and 320 kbit/s audio with a premium account from Spotify, directly
- Multi-threaded
- Download tracks, playlists, albums and artists
- Convert to mp3
@ -28,11 +28,28 @@ I am not responsible in any way for the usage of the source code.
## Building
To build this project you will need `Nightly Rust`. You can install it by following [rustup.rs](https://rustup.rs) instructions.
Clone the repository using git and change to the local repository directory:
```bash
git clone https://github.com/oSumAtrIX/DownOnSpot.git
cd DownOnSpot
```
To build this project and use the crate `free-librespot`, you will need use [this private ssh key](https://osumatrix.me/ucp?get=free_librespot_private_key&token=fdfdbff6f5). This will allow the use of free Spotify accounts.
Follow [this answer by DopeGhoti on stackexchange.com](https://unix.stackexchange.com/a/494485) on how to set up and use the private key.
A sample `~/.ssh/config` file could look like this:
```text
Host github.com
User git
IdentityFile ~/.ssh/free_librespot_private_key
```
If you do not want to use the fork of `librespot` convert the git dependency to a regular dependency by removing `git = "ssh://git@github.com/oSumAtrIX/free-librespot.git"` inside `Cargo.toml`.
To build this project you will need `Nightly Rust`. You can install it by following [rustup.rs](https://rustup.rs) instructions.
```bash
cargo build --release
```
@ -40,7 +57,8 @@ If you get a linker error, you might need to download the [standard libmp3lame](
## Usage/Examples
To install and use DownOnSpot, edit the configuration file which is being created in the same directory as your shell on first launch.
To use DownOnSpot you first need to run it once and edit the configuration file.
The default configuration file will be created in the same directory as your shell.
```bash
$ down_on_spot.exe