NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
17.28k stars 13.53k forks source link

Contributors for catppucin, why cant you just agree on a default across packages? #298926

Open max-ishere opened 5 months ago

max-ishere commented 5 months ago

I looked at my config and it is a mess with catppuccin. First of all, I am sure that every catppuccin thing uses a different variant as the default, they may even have different accents. Oh wait its not a variant, GTK Icon Theme calls it a flavor.

Can't you just choose a standard? Say blue frappe. It doesnt matter which one. Just choose one. And then there's the situation with casing. QT uses Capitalized, GTK uses lowercase. Just choose one. Come on.

Now I understand that changing the enums may be too late. But can't you just pick the same defaults lol.

eclairevoyant commented 5 months ago

Take it up with upstream, they changed capitalisation at least twice: https://github.com/catppuccin/gtk/commit/3fc72208deec4b7f8c22a2c77a21fde341e29cb6 https://github.com/catppuccin/gtk/commit/f13a2b2e08e5265436114f3f7312d9e62cb430d3

Same goes for the terminology of accent, flavor, tweaks etc. - this all comes from upstream. Flavor means which of the 4 catppuccin types to use (mocha, frappe, macchiato, latte) whereas accent refers to the accent colour used (pink, yellow, green, ...). See https://github.com/catppuccin/gtk/blob/main/install.py

keenanweaver commented 5 months ago

It did take me several rebuilds to catch all the 'gotchas' with the catppuccin packages when I first made my config. Here's a sample config:

(catppuccin-gtk.override {
  size = "standard";
  accents = [ "sky" ];
  variant = "mocha";
  tweaks = [ "rimless" ];
})
(catppuccin-kde.override {
  accents = [ "sky" ];
  flavour = [ "mocha" ];
})
(catppuccin-kvantum.override {
  variant = "Mocha";
  accent = "Sky";
})
(catppuccin-papirus-folders.override {
  accent = "sky";
  flavor = "mocha";
})
(catppuccin-plymouth.override {
  variant = [ "mocha" ];
})

Notice singular 'accent' vs. plural 'accents', spelling 'flavor' and 'flavour', terms 'variant' vs. 'flavor', And how some values are lists or just strings. In my opinion, it should be all singular with terms and spelling being 'flavor' and 'accent'. Is it considered bad nix form to have lists even if only one value is correct? Just for the ease of config use. As for the capitalization, whatever upstream is doing now is ideal (hopefully lowercase!)

eclairevoyant commented 5 months ago

spelling 'flavor' and 'flavour',

Yes, upstream cannot even standardise which spelling they want to use (e.g. flavour in kde: https://github.com/catppuccin/kde/blob/main/install.sh#L51 vs flavor in gtk: https://github.com/catppuccin/gtk/blob/main/install.py#L17).

Sure we could consider diverging from upstream, but it'd be even more confusing for a new user to read the upstream code/docs and find that nixpkgs is doing something completely different!

As for the capitalization, whatever upstream is doing now is ideal (hopefully lowercase!)

It's uppercase before 0.6.1, lowercase in 0.6.1, and uppercase again starting from 0.6.2 onwards.

keenanweaver commented 5 months ago

Oh wow.

Aleksanaa commented 5 months ago

It's uppercase before 0.6.1, lowercase in 0.6.1, and uppercase again starting from 0.6.2 onwards.

Yes and my rice broke twice lol

Aleksanaa commented 5 months ago

It is true that Nixpkgs currently cannot provide such fine-grained stability guarantees. That's not a goal at the moment either. The upstream should first unify the build tools/file formats etc.

max-ishere commented 5 months ago

Glad for the positive response. Personally what I think has to be done is in the following releases all packaged catppuccin should agree on some one default so if you don't provide overrides you get a consistent theme. Those who want a specific style will probably have that specified in their config, so I dont think it matters which combo of flavor and accent is chosen.

As for the casing, etc here's what I think should be done:

  1. Does it really matter if the word is lowercase or uppercase? Can we just somehow lowercase it before it goes into the enum?
  2. The keys such as flavor and accent should be standardized.

Ideally it would be nice to just do this everywhere:

(catppuccin-papirus-folders.override {
  inherit (config.myconfig.colors.catppuccin) accent flavor;
})

I dont think nixpkgs should have like a global catppuccin defaults key... but that would work too:

config = {
  colorscheme.catppuccin = {
    accent = "blue";
    flavor = "frappe";
  };
};

I dont expect that to ever merge tho...

max-ishere commented 5 months ago

I feel like there might be some backlash on the changes to casing and renaming the keys so I dont have any hopes for those changes, but I dont believe in backwards comaptibility so I'm ok with refactoring my config one time to make it easier to change the style later. I think its worth it.

max-ishere commented 5 months ago

Also btw there's the catppuccin package... which like... why? it just has a bunch of fetch from github... I didnt get the point... It doesnt configure some stuff like waybar for example.

Aleksanaa commented 5 months ago

Also btw there's the catppuccin package... which like... why? it just has a bunch of fetch from github... I didnt get the point... It doesnt configure some stuff like waybar for example.

It just fetches them for you. You are responsible for the rest of configuration. See home-manager for some options to embedded your theme.

Of course, the structure of this package may indeed be better adjusted, such as becoming a package set.

max-ishere commented 5 months ago

Yeah it should probably be separate packages because you can end up with multiple versions, each having a different themeList even if they share some content.

keenanweaver commented 3 months ago

Issue can probably be closed since this now exists: https://github.com/catppuccin/nix

isabelroses commented 3 months ago

I agree with @keenanweaver.

But also the issue was that we relied on colloid gtk so we did not have an awful amount of flexibility when it came to file names. This should be fixed since we now have implemented our own build system, and now https://github.com/NixOS/nixpkgs/pull/315143 that update is coming to nix, but that will change it again... -dark this time. At least for gtk. And with an update for catppuccin-cursors, https://github.com/NixOS/nixpkgs/pull/315310, we should have the flexibility to do something similar to gtk too.

As of this change it shouldn't change again. So I believe this issue can be closed.

isabelroses commented 3 months ago

But when both gtk and cursors are merged I can work on standardizing the defaults [via PR]. i.e. flavor and accent.

nullishamy commented 3 months ago

We've just changed the suffix again for the GTK package in response to a GTK3 bug. This should not break nix builds, but may impact downstream users. This is because GTK3 has obscene semantics with respect to how themes load, seemingly -dark makes the theme inapplicable to GTK3 apps, for whatever reason.

Context: https://github.com/catppuccin/gtk/pull/261

max-ishere commented 3 months ago

@keenanweaver Thanks for mentioning it, catppuccin-nix is gonna make my config so much simpler.