Skip to content

Fix Spicetify wrapper repair in Spotify setup - #196

Open
yukazakiri wants to merge 1 commit into
snowarch:mainfrom
yukazakiri:agent/spicetify-wrapper-repair
Open

Fix Spicetify wrapper repair in Spotify setup#196
yukazakiri wants to merge 1 commit into
snowarch:mainfrom
yukazakiri:agent/spicetify-wrapper-repair

Conversation

@yukazakiri

Copy link
Copy Markdown
Contributor

Summary

Fixes /setup-spotify for source-built Spicetify packages that omit the generated spicetifyWrapper.js asset introduced in Spicetify v2.44.

Upstream context

This works around the upstream Spicetify packaging/build issue documented in spicetify/cli#3888.

Spicetify maintainers explain that since v2.44.0, the wrapper was made modular and spicetifyWrapper.js is no longer checked into the repository. It is generated from src/jsHelper/spicetifyWrapper during release builds by scripts/build-wrapper.mjs. Linux packages that build Spicetify from source without running that build step can install a CLI that still injects helper/spicetifyWrapper.js into Spotify, but does not ship the file. Their recommended manual fix is to install Node/pnpm, run pnpm build:wrapper, then run spicetify apply.

Details

This PR makes the Spotify setup recipe self-heal that state by:

  • detecting a missing /opt/spicetify-cli/jsHelper/spicetifyWrapper.js
  • reusing cached paru/yay Spicetify source when available
  • downloading the matching release source when needed
  • building the wrapper with pnpm, falling back to npm
  • installing the generated wrapper into the package asset directory
  • verifying the patched Spotify XPUI helper directory has the wrapper after spicetify backup apply

It also updates the Spicetify theme reapply script to preserve an already-built wrapper across future theme reapplies, and documents the setup behavior for maintainers.

Testing

  • shellcheck scripts/setup/spotify.sh scripts/colors/apply-spicetify-theme.sh
  • bash -n scripts/setup/spotify.sh scripts/colors/apply-spicetify-theme.sh
  • bash scripts/setup/_scan.sh | jq -e '.[] | select(.slug=="spotify")'
  • git diff --check

@yukazakiri
yukazakiri force-pushed the agent/spicetify-wrapper-repair branch from c93d720 to d662cbd Compare July 10, 2026 13:08
@yukazakiri
yukazakiri marked this pull request as ready for review July 10, 2026 13:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant