switch nixfmt to alejandra to format nix code
This commit is contained in:
parent
582bdb783c
commit
e44894c666
120 changed files with 1163 additions and 1237 deletions
|
|
@ -3,8 +3,7 @@
|
|||
unixName,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
youthlic = {
|
||||
xdg-dirs.enable = true;
|
||||
programs = {
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
{ ... }: { }
|
||||
{...}: {}
|
||||
|
|
|
|||
|
|
@ -4,8 +4,7 @@
|
|||
config,
|
||||
rootPath,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
youthlic = {
|
||||
xdg-dirs.enable = true;
|
||||
programs = {
|
||||
|
|
|
|||
|
|
@ -5,8 +5,7 @@
|
|||
inputs,
|
||||
unixName,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
youthlic = {
|
||||
xdg-dirs.enable = true;
|
||||
programs = {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
{pkgs, ...}: {
|
||||
imports = [
|
||||
./wallpaper.nix
|
||||
./programs
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
{ ... }:
|
||||
{
|
||||
{...}: {
|
||||
imports = [
|
||||
./openssh.nix
|
||||
./niri
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ config, lib, ... }:
|
||||
let
|
||||
cfg = config.david.programs.niri;
|
||||
in
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
cfg = config.david.programs.niri;
|
||||
in {
|
||||
options = {
|
||||
david.programs.niri = {
|
||||
enable = lib.mkEnableOption "niri";
|
||||
|
|
|
|||
|
|
@ -3,11 +3,9 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.david.programs.openssh;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
david.programs.openssh = {
|
||||
enable = lib.mkEnableOption "openssh";
|
||||
|
|
@ -35,10 +33,9 @@ in
|
|||
};
|
||||
};
|
||||
};
|
||||
|
||||
})
|
||||
(lib.mkIf (cfg.enable && config.youthlic.programs.sops.enable) {
|
||||
programs.ssh.includes = [ config.sops.secrets.ssh-config.path ];
|
||||
programs.ssh.includes = [config.sops.secrets.ssh-config.path];
|
||||
sops.secrets = {
|
||||
"ssh-private-key/tytonidae" = {
|
||||
mode = "0600";
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ lib, config, ... }:
|
||||
let
|
||||
cfg = config.david.programs.wluma;
|
||||
in
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.david.programs.wluma;
|
||||
in {
|
||||
options = {
|
||||
david.programs.wluma = {
|
||||
enable = lib.mkEnableOption "wluma";
|
||||
|
|
|
|||
|
|
@ -3,11 +3,9 @@
|
|||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.david.wallpaper;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
david.wallpaper = {
|
||||
enable = lib.mkEnableOption "wallpaper";
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
{ inputs, ... }:
|
||||
{
|
||||
{inputs, ...}: {
|
||||
imports =
|
||||
(with inputs; [
|
||||
niri-flake.homeModules.niri
|
||||
|
|
|
|||
|
|
@ -4,13 +4,12 @@
|
|||
pkgs,
|
||||
inputs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
config = {
|
||||
nixpkgs = {
|
||||
config = {
|
||||
allowUnfree = true;
|
||||
allowUnfreePredicate = (_: true);
|
||||
allowUnfreePredicate = _: true;
|
||||
};
|
||||
overlays = [
|
||||
outputs.overlays.modifications
|
||||
|
|
|
|||
|
|
@ -1,8 +1,4 @@
|
|||
{
|
||||
inputs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
{inputs, ...}: {
|
||||
imports =
|
||||
(with inputs; [
|
||||
sops-nix.homeManagerModules.sops
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ lib, config, ... }:
|
||||
let
|
||||
cfg = config.youthlic.programs.atuin;
|
||||
in
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.atuin;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.atuin = {
|
||||
enable = lib.mkEnableOption "atuin";
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ lib, config, ... }:
|
||||
let
|
||||
cfg = config.youthlic.programs.chromium;
|
||||
in
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.chromium;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.chromium = {
|
||||
enable = lib.mkEnableOption "chromium";
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
{ ... }:
|
||||
{
|
||||
{...}: {
|
||||
imports = [
|
||||
./zed.nix
|
||||
./rustypaste-cli.nix
|
||||
|
|
|
|||
|
|
@ -3,11 +3,9 @@
|
|||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.espanso;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.espanso = {
|
||||
enable = lib.mkEnableOption "espanso";
|
||||
|
|
@ -18,7 +16,7 @@ in
|
|||
enable = true;
|
||||
package = pkgs.espanso-wayland;
|
||||
configs = {
|
||||
default = { };
|
||||
default = {};
|
||||
};
|
||||
matches = {
|
||||
base = {
|
||||
|
|
|
|||
|
|
@ -5,11 +5,9 @@
|
|||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.firefox;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.firefox = {
|
||||
enable = lib.mkEnableOption "firefox";
|
||||
|
|
@ -60,7 +58,7 @@ in
|
|||
}
|
||||
];
|
||||
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
|
||||
definedAliases = [ "@np" ];
|
||||
definedAliases = ["@np"];
|
||||
};
|
||||
"Nix Options" = {
|
||||
urls = [
|
||||
|
|
@ -78,7 +76,7 @@ in
|
|||
];
|
||||
}
|
||||
];
|
||||
definedAliases = [ "@no" ];
|
||||
definedAliases = ["@no"];
|
||||
};
|
||||
"Home Manager Options" = {
|
||||
urls = [
|
||||
|
|
@ -96,7 +94,7 @@ in
|
|||
];
|
||||
}
|
||||
];
|
||||
definedAliases = [ "hm" ];
|
||||
definedAliases = ["hm"];
|
||||
};
|
||||
"NUR Packages" = {
|
||||
urls = [
|
||||
|
|
@ -104,7 +102,7 @@ in
|
|||
template = "https://nur.nix-community.org/";
|
||||
}
|
||||
];
|
||||
definedAliases = [ "nu" ];
|
||||
definedAliases = ["nu"];
|
||||
};
|
||||
"Nix Flakes" = {
|
||||
urls = [
|
||||
|
|
@ -122,7 +120,7 @@ in
|
|||
];
|
||||
}
|
||||
];
|
||||
definedAliases = [ "nf" ];
|
||||
definedAliases = ["nf"];
|
||||
};
|
||||
"NixOS Wiki" = {
|
||||
urls = [
|
||||
|
|
@ -136,7 +134,7 @@ in
|
|||
];
|
||||
}
|
||||
];
|
||||
definedAliases = [ "nw" ];
|
||||
definedAliases = ["nw"];
|
||||
};
|
||||
"bing".metaData.hidden = true;
|
||||
"google".metaData.alias = "@g"; # builtin engines only support specifying one additional alias
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ config, lib, ... }:
|
||||
let
|
||||
cfg = config.youthlic.programs.foot;
|
||||
in
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.foot;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.foot = {
|
||||
enable = lib.mkEnableOption "foot";
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ config, lib, ... }:
|
||||
let
|
||||
cfg = config.youthlic.programs.fuzzel;
|
||||
in
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.fuzzel;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.fuzzel = {
|
||||
enable = lib.mkEnableOption "fuzzel";
|
||||
|
|
|
|||
|
|
@ -3,61 +3,58 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
options = {
|
||||
youthlic.programs.ghostty = {
|
||||
enable = lib.mkEnableOption "ghostty";
|
||||
};
|
||||
};
|
||||
config =
|
||||
let
|
||||
cfg = config.youthlic.programs.ghostty;
|
||||
in
|
||||
(lib.mkIf cfg.enable {
|
||||
programs.ghostty = lib.mkMerge [
|
||||
{
|
||||
enable = true;
|
||||
package = pkgs.ghostty;
|
||||
settings = {
|
||||
# font-family = "FiraCode Nerd Font";
|
||||
# font-feature = [
|
||||
# "calt=1"
|
||||
# "clig=1"
|
||||
# "liga=1"
|
||||
# "cv01"
|
||||
# "cv02"
|
||||
# "cv06"
|
||||
# "zero"
|
||||
# "onum"
|
||||
# "cv17"
|
||||
# "ss05"
|
||||
# "ss03"
|
||||
# "cv16"
|
||||
# "cv31"
|
||||
# "cv29"
|
||||
# "cv30"
|
||||
# ];
|
||||
config = let
|
||||
cfg = config.youthlic.programs.ghostty;
|
||||
in (lib.mkIf cfg.enable {
|
||||
programs.ghostty = lib.mkMerge [
|
||||
{
|
||||
enable = true;
|
||||
package = pkgs.ghostty;
|
||||
settings = {
|
||||
# font-family = "FiraCode Nerd Font";
|
||||
# font-feature = [
|
||||
# "calt=1"
|
||||
# "clig=1"
|
||||
# "liga=1"
|
||||
# "cv01"
|
||||
# "cv02"
|
||||
# "cv06"
|
||||
# "zero"
|
||||
# "onum"
|
||||
# "cv17"
|
||||
# "ss05"
|
||||
# "ss03"
|
||||
# "cv16"
|
||||
# "cv31"
|
||||
# "cv29"
|
||||
# "cv30"
|
||||
# ];
|
||||
|
||||
# font-family = "Maple Mono SC NF";
|
||||
font-feature = [
|
||||
"calt"
|
||||
"zero"
|
||||
"cv03"
|
||||
"ss08"
|
||||
];
|
||||
font-size = lib.mkForce 17;
|
||||
# theme = "ayu";
|
||||
background-opacity = lib.mkForce 0.8;
|
||||
confirm-close-surface = "false";
|
||||
};
|
||||
}
|
||||
(lib.mkIf config.youthlic.programs.fish.enable {
|
||||
enableFishIntegration = true;
|
||||
})
|
||||
(lib.mkIf config.youthlic.programs.bash.enable {
|
||||
enableBashIntegration = true;
|
||||
})
|
||||
];
|
||||
});
|
||||
# font-family = "Maple Mono SC NF";
|
||||
font-feature = [
|
||||
"calt"
|
||||
"zero"
|
||||
"cv03"
|
||||
"ss08"
|
||||
];
|
||||
font-size = lib.mkForce 17;
|
||||
# theme = "ayu";
|
||||
background-opacity = lib.mkForce 0.8;
|
||||
confirm-close-surface = "false";
|
||||
};
|
||||
}
|
||||
(lib.mkIf config.youthlic.programs.fish.enable {
|
||||
enableFishIntegration = true;
|
||||
})
|
||||
(lib.mkIf config.youthlic.programs.bash.enable {
|
||||
enableBashIntegration = true;
|
||||
})
|
||||
];
|
||||
});
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,8 +2,7 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
options = {
|
||||
youthlic.programs.git = {
|
||||
email = lib.mkOption {
|
||||
|
|
@ -31,10 +30,9 @@
|
|||
encrypt-credential = lib.mkEnableOption "encrypt git credential";
|
||||
};
|
||||
};
|
||||
config =
|
||||
let
|
||||
cfg = config.youthlic.programs.git;
|
||||
in
|
||||
config = let
|
||||
cfg = config.youthlic.programs.git;
|
||||
in
|
||||
lib.mkMerge [
|
||||
{
|
||||
programs.lazygit = {
|
||||
|
|
|
|||
|
|
@ -4,17 +4,15 @@
|
|||
lib,
|
||||
outputs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
options = {
|
||||
youthlic.programs.gpg = {
|
||||
enable = lib.mkEnableOption "gpg";
|
||||
};
|
||||
};
|
||||
config =
|
||||
let
|
||||
cfg = config.youthlic.programs.gpg;
|
||||
in
|
||||
config = let
|
||||
cfg = config.youthlic.programs.gpg;
|
||||
in
|
||||
lib.mkIf cfg.enable {
|
||||
services.gpg-agent = lib.mkMerge [
|
||||
{
|
||||
|
|
|
|||
|
|
@ -4,17 +4,15 @@
|
|||
config,
|
||||
outputs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
options = {
|
||||
youthlic.programs.helix = {
|
||||
enable = lib.mkEnableOption "helix";
|
||||
extraPackages = lib.mkOption {
|
||||
type = lib.types.listOf lib.types.package;
|
||||
default = [ ];
|
||||
default = [];
|
||||
example = (
|
||||
with pkgs;
|
||||
[
|
||||
with pkgs; [
|
||||
deno
|
||||
]
|
||||
);
|
||||
|
|
@ -24,236 +22,232 @@
|
|||
};
|
||||
};
|
||||
};
|
||||
config =
|
||||
let
|
||||
cfg = config.youthlic.programs.helix;
|
||||
in
|
||||
{
|
||||
stylix.targets.helix.enable = false;
|
||||
programs.helix = lib.mkIf cfg.enable {
|
||||
enable = true;
|
||||
package = outputs.packages."${pkgs.system}".helix;
|
||||
defaultEditor = true;
|
||||
extraPackages = cfg.extraPackages;
|
||||
settings =
|
||||
let
|
||||
config-file = builtins.readFile ./config.toml;
|
||||
config = builtins.fromTOML config-file;
|
||||
in
|
||||
config;
|
||||
languages = {
|
||||
language-server = {
|
||||
neocmakelsp = {
|
||||
command = "neocmakelsp";
|
||||
args = [
|
||||
"stdio"
|
||||
];
|
||||
};
|
||||
fish-lsp = {
|
||||
command = "fish-lsp";
|
||||
args = [
|
||||
"start"
|
||||
];
|
||||
};
|
||||
config = let
|
||||
cfg = config.youthlic.programs.helix;
|
||||
in {
|
||||
stylix.targets.helix.enable = false;
|
||||
programs.helix = lib.mkIf cfg.enable {
|
||||
enable = true;
|
||||
package = outputs.packages."${pkgs.system}".helix;
|
||||
defaultEditor = true;
|
||||
extraPackages = cfg.extraPackages;
|
||||
settings = let
|
||||
config-file = builtins.readFile ./config.toml;
|
||||
config = builtins.fromTOML config-file;
|
||||
in
|
||||
config;
|
||||
languages = {
|
||||
language-server = {
|
||||
neocmakelsp = {
|
||||
command = "neocmakelsp";
|
||||
args = [
|
||||
"stdio"
|
||||
];
|
||||
};
|
||||
fish-lsp = {
|
||||
command = "fish-lsp";
|
||||
args = [
|
||||
"start"
|
||||
];
|
||||
};
|
||||
language = [
|
||||
{
|
||||
name = "cmake";
|
||||
language-servers = [
|
||||
"neocmakelsp"
|
||||
"cmake-language-server"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "kdl";
|
||||
formatter = {
|
||||
command = "kdlfmt";
|
||||
args = [
|
||||
"format"
|
||||
"-"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "just";
|
||||
formatter = {
|
||||
command = "just";
|
||||
args = [
|
||||
"--dump"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "nix";
|
||||
formatter = {
|
||||
command = "nixfmt";
|
||||
args = [ "-" ];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "xml";
|
||||
formatter = {
|
||||
command = "xmllint";
|
||||
args = [
|
||||
"--format"
|
||||
"-"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "typst";
|
||||
formatter = {
|
||||
command = "typstyle";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "c";
|
||||
formatter = {
|
||||
command = "clang-format";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "cpp";
|
||||
formatter = {
|
||||
command = "clang-format";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "python";
|
||||
formatter = {
|
||||
command = "ruff";
|
||||
args = [
|
||||
"format"
|
||||
"-s"
|
||||
"--line-length"
|
||||
"88"
|
||||
"-"
|
||||
];
|
||||
};
|
||||
language-servers = [
|
||||
"pyright"
|
||||
"ruff"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "go";
|
||||
formatter = {
|
||||
command = "goimports";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "awk";
|
||||
formatter = {
|
||||
command = "awk";
|
||||
timeout = 5;
|
||||
args = [
|
||||
"--file=/dev/stdin"
|
||||
"--pretty-print=/dev/stdout"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "fish";
|
||||
language-servers = [
|
||||
"fish-lsp"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "yaml";
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"yaml"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "html";
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"html"
|
||||
];
|
||||
};
|
||||
language-servers = [
|
||||
"vscode-html-language-server"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "css";
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"css"
|
||||
];
|
||||
};
|
||||
language-servers = [
|
||||
"vscode-css-language-server"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "toml";
|
||||
formatter = {
|
||||
command = "taplo";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "markdown";
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"md"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "json";
|
||||
language-servers = [
|
||||
"vscode-json-language-server"
|
||||
];
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"json"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "jsonc";
|
||||
language-servers = [
|
||||
"vscode-json-language-server"
|
||||
];
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"jsonc"
|
||||
];
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
language = [
|
||||
{
|
||||
name = "cmake";
|
||||
language-servers = [
|
||||
"neocmakelsp"
|
||||
"cmake-language-server"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "kdl";
|
||||
formatter = {
|
||||
command = "kdlfmt";
|
||||
args = [
|
||||
"format"
|
||||
"-"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "just";
|
||||
formatter = {
|
||||
command = "just";
|
||||
args = [
|
||||
"--dump"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "nix";
|
||||
formatter = {
|
||||
command = "alejandra";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "xml";
|
||||
formatter = {
|
||||
command = "xmllint";
|
||||
args = [
|
||||
"--format"
|
||||
"-"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "typst";
|
||||
formatter = {
|
||||
command = "typstyle";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "c";
|
||||
formatter = {
|
||||
command = "clang-format";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "cpp";
|
||||
formatter = {
|
||||
command = "clang-format";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "python";
|
||||
formatter = {
|
||||
command = "ruff";
|
||||
args = [
|
||||
"format"
|
||||
"-s"
|
||||
"--line-length"
|
||||
"88"
|
||||
"-"
|
||||
];
|
||||
};
|
||||
language-servers = [
|
||||
"pyright"
|
||||
"ruff"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "go";
|
||||
formatter = {
|
||||
command = "goimports";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "awk";
|
||||
formatter = {
|
||||
command = "awk";
|
||||
timeout = 5;
|
||||
args = [
|
||||
"--file=/dev/stdin"
|
||||
"--pretty-print=/dev/stdout"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "fish";
|
||||
language-servers = [
|
||||
"fish-lsp"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "yaml";
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"yaml"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "html";
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"html"
|
||||
];
|
||||
};
|
||||
language-servers = [
|
||||
"vscode-html-language-server"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "css";
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"css"
|
||||
];
|
||||
};
|
||||
language-servers = [
|
||||
"vscode-css-language-server"
|
||||
];
|
||||
}
|
||||
{
|
||||
name = "toml";
|
||||
formatter = {
|
||||
command = "taplo";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "markdown";
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"md"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "json";
|
||||
language-servers = [
|
||||
"vscode-json-language-server"
|
||||
];
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"json"
|
||||
];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "jsonc";
|
||||
language-servers = [
|
||||
"vscode-json-language-server"
|
||||
];
|
||||
formatter = {
|
||||
command = "deno";
|
||||
args = [
|
||||
"fmt"
|
||||
"-"
|
||||
"--ext"
|
||||
"jsonc"
|
||||
];
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,11 +3,9 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.jujutsu;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.jujutsu = {
|
||||
enable = lib.mkEnableOption "jujutsu";
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ config, lib, ... }:
|
||||
let
|
||||
cfg = config.youthlic.programs.kvm;
|
||||
in
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.kvm;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.kvm = {
|
||||
enable = lib.mkEnableOption "kvm";
|
||||
|
|
@ -12,8 +14,8 @@ in
|
|||
dconf = {
|
||||
settings = {
|
||||
"org/virt-manager/virt-manager/connections" = {
|
||||
autoconnect = [ "qemu:///system" ];
|
||||
uris = [ "qemu:///system" ];
|
||||
autoconnect = ["qemu:///system"];
|
||||
uris = ["qemu:///system"];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ lib, config, ... }:
|
||||
let
|
||||
cfg = config.youthlic.programs.mpv;
|
||||
in
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.mpv;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.mpv = {
|
||||
enable = lib.mkEnableOption "mpv";
|
||||
|
|
|
|||
|
|
@ -4,12 +4,10 @@
|
|||
lib,
|
||||
osConfig ? null,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.niri;
|
||||
niri = osConfig.programs.niri.package;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.niri = {
|
||||
enable = lib.mkEnableOption "niri";
|
||||
|
|
@ -32,36 +30,34 @@ in
|
|||
wl-clipboard
|
||||
cliphist
|
||||
])
|
||||
++ [ niri ];
|
||||
++ [niri];
|
||||
qt = {
|
||||
enable = true;
|
||||
};
|
||||
xdg.portal = {
|
||||
configPackages = [ niri ];
|
||||
configPackages = [niri];
|
||||
enable = true;
|
||||
extraPortals = lib.mkIf (
|
||||
!niri.cargoBuildNoDefaultFeatures || builtins.elem "xdp-gnome-screencast" niri.cargoBuildFeatures
|
||||
) [ pkgs.xdg-desktop-portal-gnome ];
|
||||
) [pkgs.xdg-desktop-portal-gnome];
|
||||
};
|
||||
xdg.configFile =
|
||||
let
|
||||
qtctConf =
|
||||
''
|
||||
[Appearance]
|
||||
standard_dialogs=xdgdesktopportal
|
||||
''
|
||||
+ lib.optionalString (config.qt.style ? name) ''
|
||||
style=${config.qt.style.name}
|
||||
'';
|
||||
in
|
||||
{
|
||||
"qt5ct/qt5ct.conf" = lib.mkForce {
|
||||
text = qtctConf;
|
||||
};
|
||||
"qt6ct/qt6ct.conf" = lib.mkForce {
|
||||
text = qtctConf;
|
||||
};
|
||||
xdg.configFile = let
|
||||
qtctConf =
|
||||
''
|
||||
[Appearance]
|
||||
standard_dialogs=xdgdesktopportal
|
||||
''
|
||||
+ lib.optionalString (config.qt.style ? name) ''
|
||||
style=${config.qt.style.name}
|
||||
'';
|
||||
in {
|
||||
"qt5ct/qt5ct.conf" = lib.mkForce {
|
||||
text = qtctConf;
|
||||
};
|
||||
"qt6ct/qt6ct.conf" = lib.mkForce {
|
||||
text = qtctConf;
|
||||
};
|
||||
};
|
||||
youthlic.programs = {
|
||||
fuzzel.enable = true;
|
||||
wluma.enable = true;
|
||||
|
|
|
|||
|
|
@ -3,11 +3,9 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.obs;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.obs = {
|
||||
enable = lib.mkEnableOption "obs";
|
||||
|
|
|
|||
|
|
@ -3,22 +3,20 @@
|
|||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.rustypaste-cli;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.rustypaste-cli = {
|
||||
enable = lib.mkEnableOption "rustypaste-cli";
|
||||
};
|
||||
};
|
||||
config = lib.mkIf cfg.enable {
|
||||
home.packages = [ pkgs.rustypaste-cli ];
|
||||
home.packages = [pkgs.rustypaste-cli];
|
||||
sops = {
|
||||
secrets = {
|
||||
"rustypaste/auth" = { };
|
||||
"rustypaste/delete" = { };
|
||||
"rustypaste/auth" = {};
|
||||
"rustypaste/delete" = {};
|
||||
};
|
||||
templates."rustypaste-config.toml" = {
|
||||
path = "${config.xdg.configHome}/rustypaste/config.toml";
|
||||
|
|
|
|||
|
|
@ -2,13 +2,11 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
inherit (lib) mkEnableOption mkIf mkMerge;
|
||||
fish-cfg = config.youthlic.programs.fish;
|
||||
bash-cfg = config.youthlic.programs.bash;
|
||||
cfg-helper =
|
||||
conf:
|
||||
cfg-helper = conf:
|
||||
mkMerge [
|
||||
conf
|
||||
(mkIf fish-cfg.enable {
|
||||
|
|
@ -18,8 +16,7 @@ let
|
|||
enableBashIntegration = true;
|
||||
})
|
||||
];
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs = {
|
||||
fish = {
|
||||
|
|
|
|||
|
|
@ -4,8 +4,7 @@
|
|||
pkgs,
|
||||
rootPath,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
options = {
|
||||
youthlic.programs.sops = {
|
||||
enable = lib.mkOption {
|
||||
|
|
@ -25,14 +24,12 @@
|
|||
};
|
||||
};
|
||||
};
|
||||
config =
|
||||
let
|
||||
cfg = config.youthlic.programs.sops;
|
||||
in
|
||||
config = let
|
||||
cfg = config.youthlic.programs.sops;
|
||||
in
|
||||
lib.mkIf cfg.enable {
|
||||
home.packages = (
|
||||
with pkgs;
|
||||
[
|
||||
with pkgs; [
|
||||
sops
|
||||
age
|
||||
]
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ lib, config, ... }:
|
||||
let
|
||||
cfg = config.youthlic.programs.starship;
|
||||
in
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.starship;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.starship = {
|
||||
enable = lib.mkEnableOption "starship";
|
||||
|
|
@ -12,10 +14,9 @@ in
|
|||
programs.starship = lib.mkMerge [
|
||||
{
|
||||
enable = true;
|
||||
settings =
|
||||
let
|
||||
config-file = builtins.readFile ./config.toml;
|
||||
in
|
||||
settings = let
|
||||
config-file = builtins.readFile ./config.toml;
|
||||
in
|
||||
builtins.fromTOML config-file;
|
||||
}
|
||||
(lib.mkIf config.youthlic.programs.fish.enable {
|
||||
|
|
|
|||
|
|
@ -3,11 +3,9 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.swaylock;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.swaylock = {
|
||||
enable = lib.mkEnableOption "swaylock";
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ lib, config, ... }:
|
||||
let
|
||||
cfg = config.youthlic.programs.swaync;
|
||||
in
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.swaync;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.swaync = {
|
||||
enable = lib.mkEnableOption "swaync";
|
||||
|
|
@ -16,7 +18,7 @@ in
|
|||
};
|
||||
})
|
||||
(lib.mkIf (!cfg.systemd.enable) {
|
||||
systemd.user.services.swaync = lib.mkForce { };
|
||||
systemd.user.services.swaync = lib.mkForce {};
|
||||
})
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ config, lib, ... }:
|
||||
let
|
||||
cfg = config.youthlic.programs.thunderbird;
|
||||
in
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.thunderbird;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.thunderbird = {
|
||||
enable = lib.mkEnableOption "thunderbird";
|
||||
|
|
|
|||
|
|
@ -3,11 +3,9 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.waybar;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.waybar = {
|
||||
enable = lib.mkEnableOption "waybar";
|
||||
|
|
@ -26,7 +24,7 @@ in
|
|||
"niri/workspaces"
|
||||
"wlr/taskbar"
|
||||
];
|
||||
modules-center = [ "clock" ];
|
||||
modules-center = ["clock"];
|
||||
modules-right = [
|
||||
"tray"
|
||||
"idle_inhibitor"
|
||||
|
|
@ -40,7 +38,7 @@ in
|
|||
on-click = "activate";
|
||||
};
|
||||
|
||||
"niri/worksapces" = { };
|
||||
"niri/worksapces" = {};
|
||||
"niri/taskbar" = {
|
||||
icon-size = 15;
|
||||
on-click = "activate";
|
||||
|
|
|
|||
|
|
@ -3,11 +3,9 @@
|
|||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.wluma;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.wluma = {
|
||||
enable = lib.mkEnableOption "wluma";
|
||||
|
|
@ -39,18 +37,18 @@ in
|
|||
systemd.user.services.wluma = {
|
||||
Unit = {
|
||||
Description = "Adjusting screen brightness based on screen contents and amount of ambient light";
|
||||
PartOf = [ "graphical-session.target" ];
|
||||
After = [ "graphical-session.target" ];
|
||||
PartOf = ["graphical-session.target"];
|
||||
After = ["graphical-session.target"];
|
||||
};
|
||||
Service = {
|
||||
ExecStart = [ "${lib.getExe cfg.package}" ];
|
||||
ExecStart = ["${lib.getExe cfg.package}"];
|
||||
Restart = "always";
|
||||
EnvironmentFile = [ "-%E/wluma/service.conf" ];
|
||||
EnvironmentFile = ["-%E/wluma/service.conf"];
|
||||
PrivateNetwork = true;
|
||||
PrivateMounts = false;
|
||||
};
|
||||
Install = {
|
||||
WantedBy = [ "graphical-session.target" ];
|
||||
WantedBy = ["graphical-session.target"];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -3,11 +3,9 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
cfg = config.youthlic.programs.zed-editor;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.zed-editor = {
|
||||
enable = lib.mkEnableOption "zed-editor";
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
{ lib, config, ... }:
|
||||
let
|
||||
cfg = config.youthlic.xdg-dirs;
|
||||
in
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.xdg-dirs;
|
||||
in {
|
||||
options = {
|
||||
youthlic.xdg-dirs = {
|
||||
enable = lib.mkEnableOption "xdg-dirs";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue