Discogs Cover

by Florent
5
4
3
2
1
Score: 50/100
New Plugin

Description

Shows the Discogs cover art for a note's 'discogs' release ID, cached locally and usable in Bases image columns.

Reviews

No reviews yet.

Stats

0
stars
0
downloads
0
forks
0
days
1
days
1
days
0
total PRs
0
open PRs
0
closed PRs
0
merged PRs
0
total issues
0
open issues
0
closed issues
3
commits

Latest Version

a day ago

Changelog

Fix: the plugin failed to load for every user (Cannot find module './i18n'). Localization strings are now inlined directly in main.js, as Obsidian's plugin loader does not resolve require() to other files inside the plugin folder.

README file from

Github

Discogs Cover

Shows the Discogs cover art for a note whenever its frontmatter has a discogs property (a release ID, or a Discogs release URL containing one). The cover is displayed above the note title in both Reading view and Live Preview, and the same local cache can be reused from a Base image column.

Features

  • Displays the cover above the title in Reading view and Live Preview
  • Downloads each cover once and caches it locally in the vault (_discogs-covers/<releaseId>.jpg), so it works offline and never re-downloads the same release
  • The cache is a normal vault folder, so it can be referenced from a Base formula, e.g.:
    formulas:
      discogs_image: 'link("_discogs-covers/" + discogs + ".jpg")'
    
  • Command to pre-fill the cache for every note at once: "Cache all Discogs covers"
  • Optional personal Discogs API token (raises the rate limit from 25 to 60 requests/min)
  • Configurable image size and alignment
  • Interface available in English and French (follows Obsidian's own display language)

How it works

  1. Add a discogs property to a note's frontmatter, with the release ID (e.g. discogs: "395976") or a Discogs release URL.
  2. Open the note in Reading view or Live Preview: the cover appears above the title.
  3. The image is fetched once from the Discogs API, saved under _discogs-covers/ in your vault, and reused from there afterwards.

To pre-populate the cache for every note that has a discogs property (useful before browsing a Base gallery), run "Cache all Discogs covers" from the command palette.

Permissions

The "Cache all Discogs covers" command lists every markdown file in the vault (vault.getMarkdownFiles()) in order to find the ones with a discogs property and pre-fill the local cache for all of them at once. No file content is read beyond its already-indexed frontmatter, and nothing ever leaves the vault except the Discogs release ID sent to api.discogs.com.

Settings

  • Maximum image size — max width/height of the cover, in pixels (default 300).
  • Alignment — left / center / right.
  • Discogs token (optional) — a personal access token from discogs.com/settings/developers. Without it, Discogs limits requests to 25/min; with it, 60/min. The token is only used in the Authorization header of requests to api.discogs.com and is never sent anywhere else.

Installation

This plugin isn't on the community plugin list yet. To install it manually:

  1. Download main.js, manifest.json and styles.css from the latest release.
  2. Create a folder named discogs-cover inside your vault's .obsidian/plugins/ directory.
  3. Copy the three files into that folder.
  4. In Obsidian, go to Settings → Community plugins, and enable Discogs Cover.

License

MIT