mirror of
https://github.com/JonasunderscoreJones/docs.jonasjones.dev.git
synced 2025-10-23 02:59:18 +02:00
added turbo-octo-potato docs
This commit is contained in:
parent
f5744d0cab
commit
0a9689d5e3
8 changed files with 607 additions and 0 deletions
10
docs/turbo-octo-potato/spotify-scripts/_category_.json
Normal file
10
docs/turbo-octo-potato/spotify-scripts/_category_.json
Normal file
|
@ -0,0 +1,10 @@
|
|||
{
|
||||
"position": 2,
|
||||
"label": "Spotify Scripts",
|
||||
"collapsible": true,
|
||||
"collapsed": true,
|
||||
"link": {
|
||||
"type": "generated-index",
|
||||
"description": "Documentation for the Spotify scripts"
|
||||
}
|
||||
}
|
58
docs/turbo-octo-potato/spotify-scripts/discographymaker.mdx
Normal file
58
docs/turbo-octo-potato/spotify-scripts/discographymaker.mdx
Normal file
|
@ -0,0 +1,58 @@
|
|||
# Discography Maker
|
||||
View this script on [GitHub](https://github.com/JonasunderscoreJones/turbo-octo-potato/blob/main/spotify_scripts/discographymaker.py)
|
||||
|
||||
This script fetches all songs of all albums/EP's/Singles of the artists you choose and puts them in chronological order into a playlist.
|
||||
|
||||
## Setup
|
||||
The script requires a few environment variables to be set. For this, populate the `.env` file with the following variables:
|
||||
```properties title="../.env"
|
||||
SPOTIFY_CLIENT_ID=[your spotify client ID]
|
||||
SPOTIFY_CLIENT_SECRET=[your spotify client secret]
|
||||
SPOTIFY_REDIRECT_URI=[your spotifiy redirect URI]
|
||||
SPOTIFY_USER_ID=[your spotify user id]
|
||||
```
|
||||
For more info on how to get the `client id`, `cliene secret` and `redirect uri` visit the [Spotify API Docs](https://developer.spotify.com/documentation/web-api#getting-started) for creating an app
|
||||
|
||||
## Usage
|
||||
Inside the repository directory run the script by executing:
|
||||
```bash
|
||||
python spotify_scripts/discographymaker.py
|
||||
```
|
||||
You will be asked to enter the names (one at a time) of the artists You would like to be in a new discography playlist.
|
||||
```bash
|
||||
Authenticating...
|
||||
Authenticated!
|
||||
Input your first Artist (name, spotify ID or artist link). Enter other's when prompted next:
|
||||
```
|
||||
If Your input matches the found artist's name perfectly, then You won't have to confirm it:
|
||||
```bash
|
||||
Input your first Artist (name, spotify ID or artist link). Enter other's when prompted next:
|
||||
ATEEZ
|
||||
Looking up Artist...
|
||||
======================
|
||||
Input your next Artist (name or Spotify ID). Leave empty if all have been inputed
|
||||
```
|
||||
If the found artist's name differs, You will be asked for comfirmation:
|
||||
```bash
|
||||
Input your next Artist (name or Spotify ID). Leave empty if all have been inputed
|
||||
ateez
|
||||
Looking up Artist...
|
||||
The Artist doesn't exist on Spotify. Did you mean "ATEEZ" [ENTER for Yes, No for retry]:
|
||||
```
|
||||
In case it found a different artist, You can choose to retry the search.
|
||||
|
||||
Alternatively the scripts also allows inputs for the artist link or ID.
|
||||
|
||||
:::note
|
||||
|
||||
The spotify search by name feature isn't always that accurate so pasting the direct artist link or ID into the input is sometimes the only option.
|
||||
|
||||
:::
|
||||
|
||||
:::info
|
||||
|
||||
Because of a bug in the Spotify API, if an artist has more than 50 albums/EP's/Singles, the script will only fetch the first 50.
|
||||
|
||||
I am unable to fix this since it's a bug on Spotify's end and has existed for quite a while :/
|
||||
|
||||
:::
|
31
docs/turbo-octo-potato/spotify-scripts/intro_outro_maker.mdx
Normal file
31
docs/turbo-octo-potato/spotify-scripts/intro_outro_maker.mdx
Normal file
|
@ -0,0 +1,31 @@
|
|||
# Intro Outro Playlist Maker
|
||||
View this script on [GitHub](https://github.com/JonasunderscoreJones/turbo-octo-potato/blob/main/spotify_scripts/intro_outro_maker.py)
|
||||
|
||||
The script fetches all intro's and outro's from all artists You follow on spotify and puts them into a playlist.
|
||||
|
||||
## Setup
|
||||
The script requires a few environment variables to be set. For this, populate the `.env` file with the following variables:
|
||||
```properties title="../.env"
|
||||
SPOTIFY_CLIENT_ID=[your spotify client ID]
|
||||
SPOTIFY_CLIENT_SECRET=[your spotify client secret]
|
||||
SPOTIFY_REDIRECT_URI=[your spotifiy redirect URI]
|
||||
SPOTIFY_USER_ID=[your spotify user id]
|
||||
INTROOUTROPLAYLIST_ID=[your spotify playlist ID (create this playlist beforehand)]
|
||||
```
|
||||
For more info on how to get the `client id`, `client secret` and `redirect uri` visit the [Spotify API Docs](https://developer.spotify.com/documentation/web-api#getting-started) for creating an app
|
||||
|
||||
## Usage
|
||||
Inside the repository directory run the script by executing:
|
||||
```bash
|
||||
python spotify_scripts/intro_outro_maker.py
|
||||
```
|
||||
|
||||
:::warning
|
||||
|
||||
This script has the potential to get your account temporarily rate limited by Spotify.
|
||||
|
||||
In case of a ratelimit, the script will crash. Depending on how many artists you follow, the script might crash before finishing.
|
||||
|
||||
Rate limits are not to worry about, they are temporary and will be lifted after an hour at most.
|
||||
|
||||
:::
|
33
docs/turbo-octo-potato/spotify-scripts/likedsongsync2.mdx
Normal file
33
docs/turbo-octo-potato/spotify-scripts/likedsongsync2.mdx
Normal file
|
@ -0,0 +1,33 @@
|
|||
# Liked Song Sync
|
||||
View this script on [GitHub](https://github.com/JonasunderscoreJones/turbo-octo-potato/blob/main/spotify_scripts/likedsongsync2.py)
|
||||
|
||||
The script does two things with your liked songs on spotify:
|
||||
- Adds them to a playlist that can be made public and displayed on your profile (unlike the default liked songs playlist)
|
||||
- Syncs the liked songs to your [Last.fm](https://www.last.fm/) account
|
||||
|
||||
## Setup
|
||||
The script requires a few environment variables to be set. For this, populate the `.env` file with the following variables:
|
||||
```properties title="../.env"
|
||||
SPOTIFY_CLIENT_ID=[your spotify client ID]
|
||||
SPOTIFY_CLIENT_SECRET=[your spotify client secret]
|
||||
SPOTIFY_REDIRECT_URI=[your spotifiy redirect URI]
|
||||
SPOTIFY_USER_ID=[your spotify user id]
|
||||
LASTFM_API_KEY=[your last.fm API key]
|
||||
LASTFM_API_SECRET=[your last.fm API secret]
|
||||
LASTFM_USERNAME=[your last.fm username]
|
||||
LASTFM_PASSWORD_HASH=[your last.fm password hash (use an online hasher to hash the password)]
|
||||
LIKEDSONGPLAYLIST_ID=[your spotify playlist ID (create this playlist beforehand)]
|
||||
```
|
||||
For more info on how to get the `client id`, `client secret` and `redirect uri` visit the [Spotify API Docs](https://developer.spotify.com/documentation/web-api#getting-started) for creating an app
|
||||
|
||||
For more info on how to get the `API key` and `API secret` visit the [Last.fm API Docs](https://www.last.fm/api/authentication) for applying for a key.
|
||||
|
||||
## Usage
|
||||
Inside the repository directory run the script by executing:
|
||||
```bash
|
||||
python spotify_scripts/likedsongsync2.py [commandline arguments]
|
||||
```
|
||||
The script has the following commandline arguments:
|
||||
- Verbose Logging (`--verbose` or `-v`): This will print out more information about what the script is doing
|
||||
- Force Resync: (`--force-all` or `-f`): This will force the script to resync all liked songs to Last.fm, even if they have been synced before. By default the script will only sync new liked songs.
|
||||
- Skip Song Sync: (`--skip-sync` or `-s`): This will skip the syncing of a specific song.
|
Loading…
Add table
Add a link
Reference in a new issue