Created
April 9, 2019 11:42
-
-
Save ta264/77443a3de790babbd4f5ce6b9af64f4d to your computer and use it in GitHub Desktop.
Beets import script
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
BEET_CONFIG="/home/tom/.config/beets/config.yaml" | |
set -e | |
echo "$lidarr_addedtrackpaths" | |
lidarr_first_track=$(echo "$lidarr_addedtrackpaths" | cut -d '|' -f1) | |
lidarr_album_path=$(dirname "$lidarr_first_track") | |
echo "Path: $lidarr_album_path" | |
echo "Album MBID: $lidarr_album_mbid" | |
echo "Release MBID: $lidarr_albumrelease_mbid" | |
echo "Running beet import" | |
beet -c "$BEET_CONFIG" update "path:$lidarr_album_path" || true | |
beet -c "$BEET_CONFIG" import -q --search-id "$lidarr_albumrelease_mbid" "$lidarr_album_path" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Just wondering if this is still valid as I wasn't able to locate lidarr_addedtrackpaths or lidarr_albumrelease_mbid on the https://github.com/lidarr/Lidarr/wiki/Custom-Post-Processing-Scripts page?