Soho vibes for Nix
Find a file
seth a30f0ff077
feat: limit use of IFD, add auto updates & vm testing (#40)
* feat(modules): remove unnecessary IFD

by moving all upstream repos to our flake inputs, we no longer need
to have [IFD](https://nixos.wiki/wiki/Import_From_Derivation) in most
of our modules - making evaluation faster for all configurations. the
only remaining instances of IFD are in `lib.ctp.toYAML` and the themes
for kitty, which is due to it's use upstream in home-manager

* ci: start auto updating flake inputs

* ci: init basic vm tests

* ci: rename ci to format

* ci: use PAT for update-lock workflow

this is required to run tests such as test-vm after the pull request is
made

* fix(home-manager): make sure to use readFile in helix module

* ci: fix typo in test-vm

* ci: use verbose logging in test-vm & enable kvm

* docs: add flake inputs & vm testing to CONTRIBUTING.md

* feat(modules)!: use nvfetcher for upstream sources

* docs: add information about nvfetcher

* chore: don't include flake-compat in flake inputs

while this does make us lose out on easy updating, i think it's nice not
  have this as a required dependency for flake users

* chore: update flake inputs

Flake lock file updates:

• Updated input 'home-manager':
    'github:nix-community/home-manager/f58889c07efa8e1328fdf93dc1796ec2a5c47f38' (2023-07-29)
  → 'github:nix-community/home-manager/48b0a30202516e25d9885525fbb200a045f23f26' (2023-11-01)
• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/2a9d660ff0f7ffde9d73be328ee6e6f10ef66b28' (2023-07-28)
  → 'github:NixOS/nixpkgs/0cbe9f69c234a7700596e943bfae7ef27a31b735' (2023-10-29)

* chore: update nvfetcher sources

* refactor: don't instantiate nixpkgs in flake + cleanup vm test

* fix(home-manager): update paths from new lazygit theme revision

* feat(lib)!: use constant module arguments automatically
2023-11-02 13:55:47 -04:00
.github/workflows feat: limit use of IFD, add auto updates & vm testing (#40) 2023-11-02 13:55:47 -04:00
_sources feat: limit use of IFD, add auto updates & vm testing (#40) 2023-11-02 13:55:47 -04:00
assets/previews chore: add project previews (#35) 2023-06-25 20:16:54 -04:00
docs feat: add autogenerated docs (#39) 2023-07-29 08:40:13 -04:00
modules feat: limit use of IFD, add auto updates & vm testing (#40) 2023-11-02 13:55:47 -04:00
.editorconfig feat: initial commit 2023-03-26 21:15:25 -04:00
.gitignore feat: initial commit 2023-03-26 21:15:25 -04:00
CONTRIBUTING.md feat: limit use of IFD, add auto updates & vm testing (#40) 2023-11-02 13:55:47 -04:00
default.nix feat: limit use of IFD, add auto updates & vm testing (#40) 2023-11-02 13:55:47 -04:00
flake.lock feat: limit use of IFD, add auto updates & vm testing (#40) 2023-11-02 13:55:47 -04:00
flake.nix feat: limit use of IFD, add auto updates & vm testing (#40) 2023-11-02 13:55:47 -04:00
LICENSE feat: initial commit 2023-03-26 21:15:25 -04:00
nvfetcher.toml feat: limit use of IFD, add auto updates & vm testing (#40) 2023-11-02 13:55:47 -04:00
README.md chore: remove branch from relative links again 2023-06-26 13:33:04 -04:00
test.nix feat: limit use of IFD, add auto updates & vm testing (#40) 2023-11-02 13:55:47 -04:00

Logo
Catppuccin for Nix

Previews

🌻 Latte
🪴 Frappé
🌺 Macchiato
🌿 Mocha

Usage

  1. Import the NixOS and home-manager modules
With Flakes
{
  inputs = {
    nixpkgs.url = "nixpkgs/nixos-22.11";
    catppuccin.url = "github:catppuccin/nix";
    home-manager = {
      url = "github:nix-community/home-manager";
      inputs.nixpkgs.follows = "nixpkgs";
    };
  };

  outputs = { nixpkgs, catppuccin, home-manager }: let
    system = "x86_64-linux";
    pkgs = import nixpkgs {inherit system;};
  in {
    # for nixos module home-manager installations
    nixosConfigurations.host = pkgs.lib.nixosSystem {
      inherit system;
      modules = [
        catppuccin.nixosModules.catppuccin
        home-manager.nixosModules.home-manager
        {
          home-manager.users.user = {
            modules = [
              catppuccin.homeManagerModules.catppuccin
            ];
          };
        }
      ];
    };

    # for standalone home-manager installations
    homeConfigurations.user = home-manager.lib.homeManagerConfiguration {
      inherit pkgs;
      modules = [
        catppuccin.homeManagerModules.catppuccin
      ];
    };
  };
}
With Nix Channels
sudo nix-channel --add https://github.com/nix-community/home-manager/archive/master.tar.gz home-manager
sudo nix-channel --add https://github.com/catppuccin/nix/archive/main.tar.gz catppuccin
sudo nix-channel --update

For NixOS module installations:

_: {
  imports = [
    <home-manager/nixos>
    <catppuccin/modules/nixos>
  ];

  home-manager.users.user = {
    modules = [
      <catppuccin/modules/home-manager>
    ];
  };
}

For standalone installations

_: {
  imports = [
    <catppuccin/modules/home-manager>
  ];

  home.username = "user";
  home.homeDirectory = "user";
  programs.home-manager.enable = true;
}
  1. Choose your desired flavour with catppuccin.flavour
_: {
  catppuccin.flavour = "mocha";
}
  1. Enable for supported programs with catppucin.enable = true;
_: {
  programs.starship = {
    enable = true;
    catppuccin.enable = true;
  };
}

🙋 FAQ

  • Q: "How do I know what programs are supported?"
    A: You can find programs supported through home-manager here, and NixOS modules here

💝 Thanks to

 

Copyright © 2023-present Catppuccin Org