Add metadata plugins for beets
This commit is contained in:
parent
e2d22034e2
commit
c0992eda8c
@ -36,17 +36,31 @@
|
|||||||
group: "{{ music_user_name }}"
|
group: "{{ music_user_name }}"
|
||||||
mode: 0755
|
mode: 0755
|
||||||
|
|
||||||
- name: "configure beets for collection"
|
- name: "configure common beets config"
|
||||||
ansible.builtin.template:
|
ansible.builtin.blockinfile:
|
||||||
src: "./beets-collection.yml"
|
path: "{{ music_user_home_directory }}/.config/beets/{{ item }}.yaml"
|
||||||
dest: "{{ music_user_home_directory }}/.config/beets/config.yaml"
|
create: true
|
||||||
mode: 0644
|
mode: 0644
|
||||||
|
insertafter: "EOF"
|
||||||
|
marker: "# {mark} ANSIBLE MANAGED BLOCK COMMON"
|
||||||
|
block: "{{ lookup('ansible.builtin.template', './beets-common.yml') }}"
|
||||||
|
with_items:
|
||||||
|
- "config"
|
||||||
|
- "archive"
|
||||||
|
|
||||||
|
- name: "configure beets for collection"
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ music_user_home_directory }}/.config/beets/config.yaml"
|
||||||
|
insertbefore: "BOF"
|
||||||
|
marker: "# {mark} ANSIBLE MANAGED BLOCK COLLECTION"
|
||||||
|
block: "{{ lookup('ansible.builtin.template', './beets-collection.yml') }}"
|
||||||
|
|
||||||
- name: "configure beets for archive"
|
- name: "configure beets for archive"
|
||||||
ansible.builtin.template:
|
ansible.builtin.blockinfile:
|
||||||
src: "./beets-archive.yml"
|
path: "{{ music_user_home_directory }}/.config/beets/archive.yaml"
|
||||||
dest: "{{ music_user_home_directory }}/.config/beets/archive.yaml"
|
insertbefore: "BOF"
|
||||||
mode: 0644
|
marker: "# {mark} ANSIBLE MANAGED BLOCK ARCHIVE"
|
||||||
|
block: "{{ lookup('ansible.builtin.template', './beets-archive.yml') }}"
|
||||||
|
|
||||||
- name: "create nextcloud-upload config directory"
|
- name: "create nextcloud-upload config directory"
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
|
@ -1,17 +1,8 @@
|
|||||||
plugins: fetchart info
|
directory: {{ music_user_data_archive_directory }}
|
||||||
library: {{ music_user_data_archive_directory }}/library.db
|
library: {{ music_user_data_archive_directory }}/library.db
|
||||||
|
|
||||||
directory: {{ music_user_data_archive_directory }}
|
|
||||||
paths:
|
|
||||||
default: $albumartist/$year $album%aunique{}/$track $title
|
|
||||||
singleton: Non-Album/$artist/$title
|
|
||||||
comp: Compilations/$year $album%aunique{}/$track $title
|
|
||||||
import:
|
import:
|
||||||
copy: yes
|
copy: yes
|
||||||
move: no
|
move: no
|
||||||
write: no
|
write: no
|
||||||
autotag: no
|
autotag: no
|
||||||
|
|
||||||
fetchart:
|
|
||||||
sources:
|
|
||||||
- filesystem
|
|
||||||
|
@ -1,22 +1,7 @@
|
|||||||
plugins: convert fetchart info
|
|
||||||
library: {{ music_user_data_collection_directory }}/library.db
|
|
||||||
|
|
||||||
directory: {{ music_user_data_collection_directory }}
|
directory: {{ music_user_data_collection_directory }}
|
||||||
paths:
|
library: {{ music_user_data_collection_directory }}/library.db
|
||||||
default: $albumartist/$year $album%aunique{}/$track $title
|
|
||||||
singleton: Non-Album/$artist/$title
|
|
||||||
comp: Compilations/$year $album%aunique{}/$track $title
|
|
||||||
|
|
||||||
import:
|
import:
|
||||||
move: yes
|
move: yes
|
||||||
write: no
|
write: no
|
||||||
autotag: no
|
autotag: no
|
||||||
|
|
||||||
convert:
|
|
||||||
dest: /var/tmp/{{ music_user_name }}/mp3
|
|
||||||
copy_album_art: yes
|
|
||||||
embed: yes
|
|
||||||
|
|
||||||
fetchart:
|
|
||||||
sources:
|
|
||||||
- filesystem
|
|
||||||
|
53
playbooks/roles/music/org/templates/beets-common.yml
Normal file
53
playbooks/roles/music/org/templates/beets-common.yml
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
plugins: convert embedart fetchart info zero
|
||||||
|
|
||||||
|
paths:
|
||||||
|
default: $albumartist/$year $album%aunique{}/$track $title
|
||||||
|
singleton: Non-Album/$artist/$title
|
||||||
|
comp: Compilations/$year $album%aunique{}/$track $title
|
||||||
|
|
||||||
|
convert:
|
||||||
|
dest: /var/tmp/{{ music_user_name }}/mp3
|
||||||
|
copy_album_art: yes
|
||||||
|
embed: yes
|
||||||
|
|
||||||
|
embedart:
|
||||||
|
auto: no
|
||||||
|
|
||||||
|
fetchart:
|
||||||
|
sources:
|
||||||
|
- filesystem
|
||||||
|
|
||||||
|
zero:
|
||||||
|
auto: yes
|
||||||
|
fields: >-
|
||||||
|
albumstatus
|
||||||
|
albumtype
|
||||||
|
bpm
|
||||||
|
catalognum
|
||||||
|
comments
|
||||||
|
country
|
||||||
|
day
|
||||||
|
genre
|
||||||
|
genres
|
||||||
|
grouping
|
||||||
|
label
|
||||||
|
language
|
||||||
|
mb_albumartistid
|
||||||
|
mb_albumid
|
||||||
|
mb_artistid
|
||||||
|
mb_releasegroupid
|
||||||
|
mb_releasetrackid
|
||||||
|
mb_trackid
|
||||||
|
media
|
||||||
|
month
|
||||||
|
original_date
|
||||||
|
original_day
|
||||||
|
original_month
|
||||||
|
original_year
|
||||||
|
script
|
||||||
|
comments:
|
||||||
|
- "^(?!([0-9]{4}(-[0-9]{2}){0,2}(,[0-9]{2}){0,1} at |\
|
||||||
|
[0-9]{4} Remaster|\
|
||||||
|
[0-9]{4} Re-Recording))\
|
||||||
|
.*$"
|
||||||
|
update_database: true
|
Loading…
Reference in New Issue
Block a user