feat: alejandra -> nixfmt
This commit is contained in:
parent
acc6e6e825
commit
65ce9c5882
56 changed files with 737 additions and 456 deletions
|
@ -2,22 +2,25 @@
|
|||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
hm.programs.alacritty = let
|
||||
theme = pkgs.fetchurl {
|
||||
# url = "https://raw.githubusercontent.com/catppuccin/alacritty/ce476fb41f307d90f841c1a4fd7f0727c21248b2/catppuccin-macchiato.toml";
|
||||
url = "https://raw.githubusercontent.com/rose-pine/alacritty/3c3e36eb5225b0eb6f1aa989f9d9e783a5b47a83/dist/rose-pine.toml";
|
||||
hash = "sha256-MheSmzz02ZLAOS2uaclyazu6E//eikcdFydFfkio0/U=";
|
||||
};
|
||||
}:
|
||||
{
|
||||
hm.programs.alacritty =
|
||||
let
|
||||
theme = pkgs.fetchurl {
|
||||
# url = "https://raw.githubusercontent.com/catppuccin/alacritty/ce476fb41f307d90f841c1a4fd7f0727c21248b2/catppuccin-macchiato.toml";
|
||||
url = "https://raw.githubusercontent.com/rose-pine/alacritty/3c3e36eb5225b0eb6f1aa989f9d9e783a5b47a83/dist/rose-pine.toml";
|
||||
hash = "sha256-MheSmzz02ZLAOS2uaclyazu6E//eikcdFydFfkio0/U=";
|
||||
};
|
||||
|
||||
themeAttr = builtins.fromTOML (builtins.readFile theme);
|
||||
in {
|
||||
enable = true;
|
||||
settings = lib.recursiveUpdate themeAttr {
|
||||
font = {
|
||||
normal.family = "Iosevka Nerd Font";
|
||||
size = 12;
|
||||
themeAttr = builtins.fromTOML (builtins.readFile theme);
|
||||
in
|
||||
{
|
||||
enable = true;
|
||||
settings = lib.recursiveUpdate themeAttr {
|
||||
font = {
|
||||
normal.family = "Iosevka Nerd Font";
|
||||
size = 12;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -3,14 +3,17 @@
|
|||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (config.lib.file) mkOutOfStoreSymlink;
|
||||
in {
|
||||
in
|
||||
{
|
||||
home = {
|
||||
packages = [pkgs.jetbrains.rider];
|
||||
packages = [ pkgs.jetbrains.rider ];
|
||||
|
||||
file = {
|
||||
".dotnet/8".source = mkOutOfStoreSymlink "${pkgs.dotnetCorePackages.dotnet_8.sdk.unwrapped}/share/dotnet";
|
||||
".dotnet/8".source =
|
||||
mkOutOfStoreSymlink "${pkgs.dotnetCorePackages.dotnet_8.sdk.unwrapped}/share/dotnet";
|
||||
".dotnet/mono".source = mkOutOfStoreSymlink pkgs.mono;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
programs.fish.enable = true;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
hardware = {
|
||||
xone.enable = true;
|
||||
xpadneo.enable = true;
|
||||
|
@ -9,7 +10,11 @@
|
|||
osu-lazer-bin
|
||||
|
||||
(prismlauncher.override {
|
||||
jdks = [temurin-bin-21 temurin-bin-17 temurin-bin-8];
|
||||
jdks = [
|
||||
temurin-bin-21
|
||||
temurin-bin-17
|
||||
temurin-bin-8
|
||||
];
|
||||
})
|
||||
];
|
||||
|
||||
|
|
|
@ -2,9 +2,10 @@
|
|||
pkgs,
|
||||
ghostty,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
hm.home = {
|
||||
packages = [ghostty.packages.${pkgs.system}.default];
|
||||
packages = [ ghostty.packages.${pkgs.system}.default ];
|
||||
|
||||
file.".config/ghostty/config".text = ''
|
||||
theme = light:catppuccin-latte,dark:catppuccin-mocha
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{config, ...}: {
|
||||
{ config, ... }:
|
||||
{
|
||||
programs.git.enable = true;
|
||||
|
||||
hm.programs = {
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
services = {
|
||||
xserver.desktopManager.gnome.enable = true;
|
||||
displayManager = {
|
||||
|
@ -13,14 +14,14 @@
|
|||
hm.programs.gnome-shell = {
|
||||
enable = true;
|
||||
extensions = with pkgs.gnomeExtensions; [
|
||||
{package = appindicator;}
|
||||
{package = dash-to-dock;}
|
||||
{package = blur-my-shell;}
|
||||
{ package = appindicator; }
|
||||
{ package = dash-to-dock; }
|
||||
{ package = blur-my-shell; }
|
||||
];
|
||||
};
|
||||
|
||||
environment = with pkgs; {
|
||||
systemPackages = [gnome-tweaks];
|
||||
systemPackages = [ gnome-tweaks ];
|
||||
|
||||
gnome.excludePackages = [
|
||||
gnome-tour
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
# utility packages for hyprland, since you know it's not a DE
|
||||
|
||||
hm.home.packages = with pkgs; [
|
||||
|
@ -14,7 +15,10 @@
|
|||
|
||||
thunar = {
|
||||
enable = true;
|
||||
plugins = with pkgs.xfce; [thunar-volman thunar-archive-plugin];
|
||||
plugins = with pkgs.xfce; [
|
||||
thunar-volman
|
||||
thunar-archive-plugin
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -2,7 +2,8 @@
|
|||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
./hyprland-misc.nix
|
||||
./alacritty.nix
|
||||
|
@ -20,7 +21,7 @@
|
|||
};
|
||||
};
|
||||
|
||||
xdg.portal.extraPortals = with pkgs; [xdg-desktop-portal-gtk];
|
||||
xdg.portal.extraPortals = with pkgs; [ xdg-desktop-portal-gtk ];
|
||||
|
||||
hm = {
|
||||
home.packages = with pkgs; [
|
||||
|
@ -37,11 +38,24 @@
|
|||
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
settings = let
|
||||
inherit (lib) getExe getExe';
|
||||
keys = ["ampersand" "eacute" "quotedbl" "apostrophe" "parenleft" "minus" "egrave" "underscore" "ccedilla" "agrave"];
|
||||
in
|
||||
with pkgs; {
|
||||
settings =
|
||||
let
|
||||
inherit (lib) getExe getExe';
|
||||
keys = [
|
||||
"ampersand"
|
||||
"eacute"
|
||||
"quotedbl"
|
||||
"apostrophe"
|
||||
"parenleft"
|
||||
"minus"
|
||||
"egrave"
|
||||
"underscore"
|
||||
"ccedilla"
|
||||
"agrave"
|
||||
];
|
||||
in
|
||||
with pkgs;
|
||||
{
|
||||
"$mod" = "SUPER";
|
||||
"$wl-paste" = getExe' wl-clipboard "wl-paste";
|
||||
"$wpctl" = getExe' wireplumber "wpctl";
|
||||
|
@ -152,12 +166,18 @@
|
|||
++
|
||||
# Switch workspaces with mod + [0-9]
|
||||
# Move active window to a workspace with mod + SHIFT + [0-9]
|
||||
lib.flatten (builtins.map (i: let
|
||||
key = builtins.elemAt keys (i - 1);
|
||||
in [
|
||||
"$mod, ${key}, workspace, ${toString i}"
|
||||
"$mod SHIFT, ${key}, movetoworkspace, ${toString i}"
|
||||
]) (lib.range 1 10));
|
||||
lib.flatten (
|
||||
builtins.map (
|
||||
i:
|
||||
let
|
||||
key = builtins.elemAt keys (i - 1);
|
||||
in
|
||||
[
|
||||
"$mod, ${key}, workspace, ${toString i}"
|
||||
"$mod SHIFT, ${key}, movetoworkspace, ${toString i}"
|
||||
]
|
||||
) (lib.range 1 10)
|
||||
);
|
||||
|
||||
bindm = [
|
||||
"$mod, mouse:272, movewindow"
|
||||
|
|
|
@ -3,9 +3,11 @@
|
|||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (config.lib.file) mkOutOfStoreSymlink;
|
||||
in {
|
||||
in
|
||||
{
|
||||
home.file = {
|
||||
".jdks/temurin-21".source = mkOutOfStoreSymlink pkgs.temurin-bin-21;
|
||||
".jdks/temurin-17".source = mkOutOfStoreSymlink pkgs.temurin-bin-17;
|
||||
|
|
|
@ -2,7 +2,8 @@
|
|||
pkgs,
|
||||
camasca,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
services = {
|
||||
desktopManager.plasma6.enable = true;
|
||||
displayManager.sddm = {
|
||||
|
|
|
@ -1,11 +1,12 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
hm.programs.neovim = {
|
||||
enable = true;
|
||||
defaultEditor = true;
|
||||
extraLuaConfig = builtins.readFile ./init.lua;
|
||||
|
||||
extraPackages = with pkgs; [
|
||||
(lua5_1.withPackages (ps: with ps; [luarocks]))
|
||||
(lua5_1.withPackages (ps: with ps; [ luarocks ]))
|
||||
tree-sitter
|
||||
];
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
-- sets the <Leader> "key", which can be used in shortcuts
|
||||
vim.g.mapleader = ' '
|
||||
vim.g.mapleader = " "
|
||||
|
||||
vim.g.have_nerd_font = true
|
||||
|
||||
|
@ -8,7 +8,7 @@ vim.g.have_nerd_font = true
|
|||
vim.opt.number = true
|
||||
|
||||
-- enable mouse
|
||||
vim.opt.mouse = 'a'
|
||||
vim.opt.mouse = "a"
|
||||
|
||||
-- save undo history
|
||||
vim.opt.undofile = true
|
||||
|
@ -31,21 +31,19 @@ vim.opt.splitbelow = true
|
|||
vim.opt.list = true
|
||||
|
||||
-- preview substitutions (:s & :%s) while typing
|
||||
vim.opt.inccommand = 'split'
|
||||
vim.opt.inccommand = "split"
|
||||
|
||||
-- highlight the line the cursor is on
|
||||
vim.opt.cursorline = true
|
||||
|
||||
-- sync os clipboard and neovim
|
||||
vim.schedule(function()
|
||||
vim.opt.clipboard = 'unnamedplus'
|
||||
vim.opt.clipboard = "unnamedplus"
|
||||
end)
|
||||
|
||||
|
||||
-- [[ shortcuts, see `:help vim.keymap.set()` ]]
|
||||
-- hide search results when pressing esc
|
||||
vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>')
|
||||
|
||||
vim.keymap.set("n", "<Esc>", "<cmd>nohlsearch<CR>")
|
||||
|
||||
-- disable arrow keys in normal mode
|
||||
-- vim.keymap.set('n', '<left>', '<cmd>echo "Use h to move!!"<CR>')
|
||||
|
@ -57,11 +55,10 @@ vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>')
|
|||
-- Use CTRL+<hjkl> to switch between windows
|
||||
--
|
||||
-- See `:help wincmd` for a list of all window commands
|
||||
vim.keymap.set('n', '<C-h>', '<C-w><C-h>', { desc = 'Move focus to the left window' })
|
||||
vim.keymap.set('n', '<C-l>', '<C-w><C-l>', { desc = 'Move focus to the right window' })
|
||||
vim.keymap.set('n', '<C-j>', '<C-w><C-j>', { desc = 'Move focus to the lower window' })
|
||||
vim.keymap.set('n', '<C-k>', '<C-w><C-k>', { desc = 'Move focus to the upper window' })
|
||||
|
||||
vim.keymap.set("n", "<C-h>", "<C-w><C-h>", { desc = "Move focus to the left window" })
|
||||
vim.keymap.set("n", "<C-l>", "<C-w><C-l>", { desc = "Move focus to the right window" })
|
||||
vim.keymap.set("n", "<C-j>", "<C-w><C-j>", { desc = "Move focus to the lower window" })
|
||||
vim.keymap.set("n", "<C-k>", "<C-w><C-k>", { desc = "Move focus to the upper window" })
|
||||
|
||||
-- [[ plugin configuration ]]
|
||||
require("nvim-treesitter.configs").setup({
|
||||
|
|
|
@ -3,15 +3,20 @@
|
|||
pkgs,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
toml = pkgs.formats.toml {};
|
||||
in {
|
||||
}:
|
||||
let
|
||||
toml = pkgs.formats.toml { };
|
||||
in
|
||||
{
|
||||
hm.home.file.".cargo/config.toml".source = toml.generate "config.toml" {
|
||||
build.target-dir = "${config.hm.home.homeDirectory}/.cargo/target";
|
||||
|
||||
target.x86_64-unknown-linux-gnu = {
|
||||
linker = "${lib.getExe pkgs.clang}";
|
||||
rustflags = ["-C" "link-arg=-fuse-ld=${lib.getExe pkgs.mold}"];
|
||||
rustflags = [
|
||||
"-C"
|
||||
"link-arg=-fuse-ld=${lib.getExe pkgs.mold}"
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,15 +1,13 @@
|
|||
{
|
||||
hm.programs.starship = {
|
||||
enable = true;
|
||||
settings =
|
||||
{
|
||||
add_newline = false;
|
||||
settings = {
|
||||
add_newline = false;
|
||||
|
||||
directory = {
|
||||
truncation_length = 3;
|
||||
truncation_symbol = "…/";
|
||||
};
|
||||
}
|
||||
// (import ./nerd-font.nix);
|
||||
directory = {
|
||||
truncation_length = 3;
|
||||
truncation_symbol = "…/";
|
||||
};
|
||||
} // (import ./nerd-font.nix);
|
||||
};
|
||||
}
|
||||
|
|
|
@ -2,7 +2,8 @@
|
|||
pkgs,
|
||||
vscode-extensions,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (pkgs.stdenv.hostPlatform) system;
|
||||
extensions = vscode-extensions.extensions.${system};
|
||||
|
||||
|
@ -13,14 +14,16 @@
|
|||
rust-lang.rust-analyzer
|
||||
wakatime.vscode-wakatime
|
||||
];
|
||||
in {
|
||||
in
|
||||
{
|
||||
hm.programs.vscode = {
|
||||
enable = true;
|
||||
enableUpdateCheck = false;
|
||||
enableExtensionUpdateCheck = false;
|
||||
mutableExtensionsDir = false;
|
||||
|
||||
extensions = with extensions.vscode-marketplace;
|
||||
extensions =
|
||||
with extensions.vscode-marketplace;
|
||||
patched
|
||||
++ [
|
||||
# style
|
||||
|
@ -49,8 +52,12 @@ in {
|
|||
|
||||
# cpp
|
||||
mesonbuild.mesonbuild
|
||||
(ms-vscode.cmake-tools.overrideAttrs (_: {sourceRoot = "extension";}))
|
||||
(ms-vscode.makefile-tools.overrideAttrs (_: {sourceRoot = "extension";}))
|
||||
(ms-vscode.cmake-tools.overrideAttrs (_: {
|
||||
sourceRoot = "extension";
|
||||
}))
|
||||
(ms-vscode.makefile-tools.overrideAttrs (_: {
|
||||
sourceRoot = "extension";
|
||||
}))
|
||||
twxs.cmake
|
||||
xaver.clang-format
|
||||
|
||||
|
|
|
@ -3,7 +3,8 @@
|
|||
pkgs,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
hm.programs.waybar = {
|
||||
enable = true;
|
||||
style = ./style.css;
|
||||
|
@ -15,15 +16,23 @@
|
|||
height = 24;
|
||||
spacing = 2;
|
||||
|
||||
modules-left = ["hyprland/workspaces"];
|
||||
modules-center = [];
|
||||
modules-left = [ "hyprland/workspaces" ];
|
||||
modules-center = [ ];
|
||||
modules-right =
|
||||
["memory"]
|
||||
++ lib.optionals (builtins.elem "amdgpu" config.services.xserver.videoDrivers) ["custom/gpu-usage"]
|
||||
++ ["cpu" "wireplumber"]
|
||||
++ lib.optionals config.services.power-profiles-daemon.enable ["battery"]
|
||||
++ lib.optionals config.programs.light.enable ["backlight"]
|
||||
++ ["clock" "tray"];
|
||||
[ "memory" ]
|
||||
++ lib.optionals (builtins.elem "amdgpu" config.services.xserver.videoDrivers) [
|
||||
"custom/gpu-usage"
|
||||
]
|
||||
++ [
|
||||
"cpu"
|
||||
"wireplumber"
|
||||
]
|
||||
++ lib.optionals config.services.power-profiles-daemon.enable [ "battery" ]
|
||||
++ lib.optionals config.programs.light.enable [ "backlight" ]
|
||||
++ [
|
||||
"clock"
|
||||
"tray"
|
||||
];
|
||||
|
||||
"hyprland/workspaces" = {
|
||||
format = "{name}";
|
||||
|
|
|
@ -31,28 +31,30 @@
|
|||
@define-color rosewater #f4dbd6;
|
||||
|
||||
* {
|
||||
font-family: Jetbrains Mono, sans-serif;
|
||||
font-size: 12px;
|
||||
font-family:
|
||||
Jetbrains Mono,
|
||||
sans-serif;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
window#waybar {
|
||||
background-color: @base;
|
||||
color: @text;
|
||||
transition-property: background-color;
|
||||
transition-duration: .5s;
|
||||
background-color: @base;
|
||||
color: @text;
|
||||
transition-property: background-color;
|
||||
transition-duration: 0.5s;
|
||||
}
|
||||
|
||||
button {
|
||||
/* Use box-shadow instead of border so the text isn't offset */
|
||||
box-shadow: inset 0 -3px transparent;
|
||||
/* Avoid rounded borders under each button name */
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
/* Use box-shadow instead of border so the text isn't offset */
|
||||
box-shadow: inset 0 -3px transparent;
|
||||
/* Avoid rounded borders under each button name */
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
}
|
||||
|
||||
/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */
|
||||
button:hover {
|
||||
background: inherit;
|
||||
background: inherit;
|
||||
}
|
||||
|
||||
#clock,
|
||||
|
@ -72,93 +74,93 @@ button:hover {
|
|||
#idle_inhibitor,
|
||||
#scratchpad,
|
||||
#mpd {
|
||||
padding: 0 10px;
|
||||
color: @crust;
|
||||
padding: 0 10px;
|
||||
color: @crust;
|
||||
}
|
||||
|
||||
#window,
|
||||
#workspaces {
|
||||
margin: 0 4px;
|
||||
margin: 0 4px;
|
||||
}
|
||||
|
||||
/* If workspaces is the leftmost module, omit left margin */
|
||||
.modules-left>widget:first-child>#workspaces {
|
||||
margin-left: 0;
|
||||
.modules-left > widget:first-child > #workspaces {
|
||||
margin-left: 0;
|
||||
}
|
||||
|
||||
/* If workspaces is the rightmost module, omit right margin */
|
||||
.modules-right>widget:last-child>#workspaces {
|
||||
margin-right: 0;
|
||||
.modules-right > widget:last-child > #workspaces {
|
||||
margin-right: 0;
|
||||
}
|
||||
|
||||
#workspaces button {
|
||||
padding: 0 2px;
|
||||
background-color: transparent;
|
||||
color: @text;
|
||||
padding: 0 2px;
|
||||
background-color: transparent;
|
||||
color: @text;
|
||||
}
|
||||
|
||||
#workspaces button:hover {
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
#workspaces button.active {
|
||||
background-color: @surface1;
|
||||
box-shadow: inset 0 -3px @yellow;
|
||||
background-color: @surface1;
|
||||
box-shadow: inset 0 -3px @yellow;
|
||||
}
|
||||
|
||||
#workspaces button.urgent {
|
||||
background-color: @red;
|
||||
background-color: @red;
|
||||
}
|
||||
|
||||
#clock {
|
||||
background-color: @green;
|
||||
background-color: @green;
|
||||
}
|
||||
|
||||
#battery {
|
||||
background-color: @sky;
|
||||
background-color: @sky;
|
||||
}
|
||||
|
||||
#battery.low:not(.charging) {
|
||||
background-color: @red;
|
||||
background-color: @red;
|
||||
}
|
||||
|
||||
#cpu {
|
||||
background-color: @sapphire;
|
||||
background-color: @sapphire;
|
||||
}
|
||||
|
||||
#custom-gpu-usage {
|
||||
background-color: @blue;
|
||||
background-color: @blue;
|
||||
}
|
||||
|
||||
#memory {
|
||||
background-color: @lavender;
|
||||
background-color: @lavender;
|
||||
}
|
||||
|
||||
#backlight {
|
||||
background-color: @teal;
|
||||
background-color: @teal;
|
||||
}
|
||||
|
||||
#network {
|
||||
background-color: @mauve;
|
||||
background-color: @mauve;
|
||||
}
|
||||
|
||||
#wireplumber {
|
||||
background-color: @sapphire;
|
||||
background-color: @sapphire;
|
||||
}
|
||||
|
||||
#wireplumber.muted {
|
||||
color: @base;
|
||||
color: @base;
|
||||
}
|
||||
|
||||
#tray {
|
||||
background-color: @yellow;
|
||||
background-color: @yellow;
|
||||
}
|
||||
|
||||
#tray>.passive {
|
||||
-gtk-icon-effect: dim;
|
||||
#tray > .passive {
|
||||
-gtk-icon-effect: dim;
|
||||
}
|
||||
|
||||
#tray>.needs-attention {
|
||||
-gtk-icon-effect: highlight;
|
||||
background-color: #eb4d4b;
|
||||
#tray > .needs-attention {
|
||||
-gtk-icon-effect: highlight;
|
||||
background-color: #eb4d4b;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue