Gerg-L / spicetify-nix

A nix flake for configuring spicetify. Includes packaging for many popular themes and extensions.
GNU General Public License v3.0
98 stars 12 forks source link

Extensions Request #209

Closed Layer-09 closed 2 months ago

Layer-09 commented 2 months ago

The spicetify marketplace works great with regard to extensions, but it's not reproducible. I would love to see some more extensions added to this repo, specifically:

There's not much documentation on this, so I was wondering whether or not users can fetch extensions on their own. Also, I've not seen snippets added. Is there a reason behind this?

gigamonster256 commented 2 months ago

Adding theming snippets without using spicetify marketplace seems a little tricky. We'd need to fetch the snippets.json file and somehow parse it out to be able to select certain snippets and then inject the aggregated css into the theming.

As for fetching your own extensions, adding your own to this repo or a fork is generally pretty trivial. (See #210 for an example adding your requested extensions and more in about 10 minutes.) This repo has significantly simplified the installation and updates of extensions through the use of npins and helper nix code vs previous spicetify-nix helper flakes.

Layer-09 commented 2 months ago

I will keep that in mind for the future. Thank you!

Gerg-L commented 2 months ago

Eventually I need to generate extensions, themes, etc. like the marketplace does

I should also add an example for using custom plugins, but I've been contemplating if there's a better format for extensions, because currently it's a weird sudo-package

Gerg-L commented 2 months ago

Added some docs for using custom apps, themes, and extentions in https://github.com/Gerg-L/spicetify-nix/commit/3cdb8908ec3d6effe65cf6db7ea85c795889d554

Gerg-L commented 2 months ago

Added snippets in https://github.com/Gerg-L/spicetify-nix/commit/fc985306d9f52f4e710f72f456127c40d6146c6b their names are the name of the previews minus the .png/.gif use the repl to see them all

$ nix repl github:Gerg-L/spicetify-nix
Nix 2.24.0pre20240626_2dd7f8f
Type :? for help.
Loading installable 'github:Gerg-L/spicetify-nix#'...
Added 5 variables.
nix-repl> builtins.attrNames legacyPackages.x86_64-linux.snippets
[
  "Dynamic-Left-Sidebar"
  "Hide-Audiobooks-Button"
  "Hide-Friend-Activity-Button"
  "Hide-Full-Screen-Button"
  "Hide-Made-For-YOU"
  "Hide-Mini-Player-Button"
  "Hide-Podcast-Button"
  "Hide-Recently-Played"
  "Hide-Whats-New-Button"
  "More-Visible-Unplayable-Tracks"
  "Queue-Top-Side-Panel"
  "Small-Video-Button"
  "always-show-forward"
  "amogus-dancing"
  "auto-hide-friends"
  "better-lyrics-style"
  "centered-lyrics"
  "circular-album-art"
  "dark-lyrics"
  "default-progress-bar"
  "disable-recommendations"
  "duck"
  "duotone-album-art"
  "fix-DJ-icon"
  "fix-liked-button"
  "fix-liked-icon"
  "fix-listening-on"
  "fix-main-view-width"
  "fix-now-playing-icon"
  "fix-playlist-and-folder-position"
  "fix-playlist-hover"
  "fix-progress-bar"
  "fixed-episodes-icon"
  "fullscreen-hide-next-up"
  "fullscreen-hide-playing-from"
  "hide-download-button"
  "hide-friends-activity-button"
  "hide-likedSongs-card"
  "hide-lyrics-button"
  "hide-now-playing-view-button"
  "hide-play-count"
  "hide-playing-gif"
  "hide-profile-username"
  "hide-recent-searches"
  "hide-sidebar-scrollbar"
  "hover-panels"
  "left-aligned-heart-icons"
  "modern-scrollbar"
  "new-hover-panel"
  "oneko"
  "pointer"
  "pokemon-adventure"
  "pretty-lyrics"
  "remove-connect-bar"
  "remove-ep-likes"
  "remove-gradient"
  "remove-popular"
  "remove-recently-played"
  "remove-top-spacing"
  "right-cover-art"
  "rotating-coverart"
  "rounded-images"
  "rounded-now-playing"
  "smaller-right-sidebar-cover"
  "smooth-playlist-reveal-gradient"
  "smooth-progress-bar"
  "switch-sidebars"
  "thicker-bars"
  "thicker-sticky-list-icons"
  "thin-library-sidebar-rows"
]
Layer-09 commented 2 months ago

Awesome work! Now I can finally get rid of the Marketplace icon.

However, I'd like to suggest an alternative approach to the theme configuration. While the current method is understandable, I believe something more akin to how extensions and customApps are configured would be better conceived.

enabledSnippets = with spicePkgs.snippets; [
    rotating-coverart
    pointer
];

Rather than the current approach, which is:

theme = spicePkgs.themes.bloom // {
   additionalCss = builtins.concatStringsSep "\n" (with spicePkgs.snippets; [
      rotating-coverart
      pointer
   ]);
};
Gerg-L commented 2 months ago

@Layer-09 I'm a step ahead of you https://github.com/Gerg-L/spicetify-nix/blob/master/module.nix#L207-L210 https://github.com/Gerg-L/spicetify-nix/blob/master/module.nix#L294-L296

The name enabledSnippets is more consistent though... Lemme change that

Layer-09 commented 2 months ago

Yeah, that's what I like to hear. Moreover, I have documented your module in the NixOS Wiki: Spicetify-Nix

Do consider creating a SNIPPETS.md, however.