Automatic Monstercat downloader and auto-tagger
Go to file
2024-09-10 14:50:21 +03:00
.gitignore Fixed donwloader to work with direct cookie. Cleaned some files. 2024-09-10 14:50:21 +03:00
common.cpp Added cover resizing 2024-07-01 15:17:40 +03:00
common.h Added cover resizing 2024-07-01 15:17:40 +03:00
config_example.json Reworked downloaded now available. Tagging not working 2024-07-01 12:52:39 +03:00
curl_dl.cpp Fixed donwloader to work with direct cookie. Cleaned some files. 2024-09-10 14:50:21 +03:00
curl_dl.h Started migration to libcurl 2024-06-24 14:56:07 +03:00
json.hpp Added most functionality. Missing Cover manipulation and tagging. 2022-07-18 17:53:23 +03:00
main.cpp Fixed donwloader to work with direct cookie. Cleaned some files. 2024-09-10 14:50:21 +03:00
Makefile Reworked downloaded now available. Tagging not working 2024-07-01 12:52:39 +03:00
monstercat_dl.cpp Changed file naming 2024-07-09 16:42:14 +03:00
monstercat_dl.h Added donwloading tracks and files 2024-07-01 11:28:18 +03:00
README.md Fixed donwloader to work with direct cookie. Cleaned some files. 2024-09-10 14:50:21 +03:00
TODO.md Added FLAC Tagging 2024-07-01 16:04:53 +03:00

Prerequisites

Ubuntu

apt install build-essential libcurl4-gnutls-dev imagemagick eyeD3 flac

Other OS

  • make
  • g++
  • libcurl
  • imagemagick (convert executable)
  • eyeD3 executable
  • metaflac executable

Usage

There must be a file named "config.json" in the working directory with your monstercat credentials and other configurations. See config_example.json for the template.

Invoke make to compile. Requires libcurl.

Login via browser and export cid cookie to cookies.txt (Netscape format)

Invoke mcat_dl with catalog ID as extra arguments to download.

Download File Structure

Release Folder

download_path/Type/YYYY-MM-DD - CatalogID - Artist - Title

  • download_path - Set in config.json
  • Type - Album/EP/Single
  • YYYY-MM-DD - Release Date in ISO format for easy sorting
  • Artist/Title - removed featuring artists from "Artist" and added to "Title"

Cover

  • Cover(.jpg/.png) - Full resolution from Monstercat
  • Cover_small.jpg - 750x750 used to tag files

MP3 and FLAC folders

Separate folders if more than 1 track otherwise put in main folder.

Extended folder

This is where extended mixes are put into. They are in their original format.

File Naming

  • Title.(mp3/flac) - Used when only 1 track

  • Number - Title.(mp3/flac) - Used when track artist matches release artist

  • Number - Artist - Title.(mp3/flac) - Used when track artist does not match release artist

JSON Library Source

https://github.com/nlohmann/json

  • Release - 3.10.5
  • Commit - 4f8fba14066156b73f1189a2b8bd568bde5284c5

eyeD3

https://eyed3.readthedocs.io/en/latest/

  • For MP3 tagging
	// Common
	--encoding utf8
	--preserve-file-times

	// First Step - Remove Images
	--remove-all-images

	// Second Step - Change what is needed
	--add-image "...":FRONT_COVER
	--artist "..."
	--album "..."
	--title "..."
	--track ...

metaflac

https://xiph.org/flac/download.html

  • For FLAC tagging
metaflac
	// Common
	--preserve-modtime
	--no-utf8-convert

	// First Step - Remove Pictures
	--remove --block-type=PICTURE

	// Second Step - Remove Tags
	--remove-tag=TITLE
	--remove-tag=ARTIST
	--remove-tag=ALBUM
	--remove-tag=TRACKNUMBER

	// Third Step - Add
	"--import-picture-from=3|image/jpeg|||/path/to/cover"
	"--set-tag=TITLE=..."
	"--set-tag=ARTIST=..."
	"--set-tag=ALBUM=..."
	"--set-tag=TRACKNUMBER=..."
	--dont-use-padding

	file.flac

imagemagick

https://imagemagick.org/script/download.php

  • For Image Resizing
convert
	Cover
	-resize 750x750
	Cover_small.jpg