some cleanup

This commit is contained in:
Vivian 2024-03-21 20:21:07 +01:00
parent 05b317d275
commit d629b5d4ed
6 changed files with 104 additions and 615 deletions

View file

@ -50,11 +50,6 @@ programs = {
rust.enable = true;
};
riff = {
enable = true;
direnv = true;
};
firefox.enable = true;
chromium = {

View file

@ -1,3 +1,10 @@
{ ... }: {
imports = [ ./catppuccin ./nvim ./riff.nix ./vscode.nix ./git.nix ./rust.nix ];
{ ... }:
{
imports = [
./catppuccin
./nvim
./vscode.nix
./git.nix
./rust.nix
];
}

View file

@ -1,28 +0,0 @@
{ config, pkgs, lib, inputs, ... }:
with lib;
let cfg = config.programs.riff;
in {
options.programs.riff = {
enable = mkEnableOption "riff";
direnv = mkOption {
type = types.bool;
default = false;
description = ''
Whether to enable direnv support
'';
};
};
config = mkIf cfg.enable {
home.packages = [ inputs.riff.packages.${pkgs.system}.riff ];
xdg.configFile."direnv/lib/riff.sh" = mkIf cfg.direnv {
executable = true;
text = ''
use_riff() {
watch_file Cargo.toml watch_file Cargo.lock
eval "$(riff --offline print-dev-env)"
}
'';
};
};
}