run nixfmt
This commit is contained in:
parent
477bce6897
commit
9415d40508
41 changed files with 384 additions and 262 deletions
|
@ -1,5 +1,6 @@
|
|||
# Configures programs that primarily run via the command line
|
||||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./fish.nix # fish shell configuration
|
||||
./neovim.nix # neovim configuration, my "escape" editor
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ ... }: {
|
||||
{ ... }:
|
||||
{
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
|
|
|
@ -116,13 +116,12 @@
|
|||
}
|
||||
{
|
||||
name = "plugin-foreign-env";
|
||||
src = pkgs.fetchFromGitHub
|
||||
{
|
||||
owner = "oh-my-fish";
|
||||
repo = "plugin-foreign-env";
|
||||
rev = "7f0cf099ae1e1e4ab38f46350ed6757d54471de7";
|
||||
sha256 = "0d16mdgjdwln41zk44qa5vcilmlia4w15r8z2rc3p49i5ankksg3";
|
||||
};
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "oh-my-fish";
|
||||
repo = "plugin-foreign-env";
|
||||
rev = "7f0cf099ae1e1e4ab38f46350ed6757d54471de7";
|
||||
sha256 = "0d16mdgjdwln41zk44qa5vcilmlia4w15r8z2rc3p49i5ankksg3";
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
{ ... }: {
|
||||
{ ... }:
|
||||
{
|
||||
programs.lazygit.enable = true;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
_1password-gui
|
||||
];
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ config, lib, ... }: {
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
programs.alacritty = {
|
||||
enable = true;
|
||||
settings = {
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./font.nix
|
||||
./firefox.nix
|
||||
|
|
|
@ -1,11 +1,12 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
fira
|
||||
];
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
|
||||
profiles ={
|
||||
profiles = {
|
||||
"user" = {
|
||||
userChrome = ''
|
||||
* {
|
||||
|
|
|
@ -1,9 +1,10 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
fontProfiles = {
|
||||
enable = true;
|
||||
monospace = {
|
||||
family = "JetBrains Mono Nerd Font";
|
||||
package = pkgs.nerdfonts.override { fonts = ["JetBrainsMono"]; };
|
||||
package = pkgs.nerdfonts.override { fonts = [ "JetBrainsMono" ]; };
|
||||
};
|
||||
regular = {
|
||||
family = "Fira Sans";
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ ... }: {
|
||||
{ ... }:
|
||||
{
|
||||
gtk = {
|
||||
enable = true;
|
||||
};
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
vscode
|
||||
];
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./mako.nix
|
||||
./wofi.nix
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ config, lib, ... }: {
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
services.mako = {
|
||||
enable = true;
|
||||
font = lib.mkForce "${config.fontProfiles.regular.family} 12";
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ config, pkgs, ... }: {
|
||||
{ config, pkgs, ... }:
|
||||
{
|
||||
# additional deps for cava support
|
||||
home.packages = with pkgs; [
|
||||
iniparser
|
||||
|
@ -73,61 +74,63 @@
|
|||
};
|
||||
};
|
||||
|
||||
style = let
|
||||
inherit (config.lib.stylix.colors) withHashtag;
|
||||
in ''
|
||||
* {
|
||||
font-family: ${config.fontProfiles.bitmap.family}, ${config.fontProfiles.monospace.family};
|
||||
font-size: 11pt;
|
||||
padding: 0;
|
||||
}
|
||||
style =
|
||||
let
|
||||
inherit (config.lib.stylix.colors) withHashtag;
|
||||
in
|
||||
''
|
||||
* {
|
||||
font-family: ${config.fontProfiles.bitmap.family}, ${config.fontProfiles.monospace.family};
|
||||
font-size: 11pt;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
window#waybar {
|
||||
padding: 0;
|
||||
border-radius: 0.5em;
|
||||
}
|
||||
window#waybar {
|
||||
padding: 0;
|
||||
border-radius: 0.5em;
|
||||
}
|
||||
|
||||
#workspaces {
|
||||
transition: background-color .5s, color .5s;
|
||||
}
|
||||
#workspaces {
|
||||
transition: background-color .5s, color .5s;
|
||||
}
|
||||
|
||||
#workspaces button {
|
||||
padding: 0 6px;
|
||||
}
|
||||
#workspaces button {
|
||||
padding: 0 6px;
|
||||
}
|
||||
|
||||
#workspaces button.active,
|
||||
#workspaces button.focused {
|
||||
background-color: ${withHashtag.base05};
|
||||
color: ${withHashtag.base00};
|
||||
}
|
||||
#workspaces button.active,
|
||||
#workspaces button.focused {
|
||||
background-color: ${withHashtag.base05};
|
||||
color: ${withHashtag.base00};
|
||||
}
|
||||
|
||||
#cpu,
|
||||
#memory {
|
||||
color: ${withHashtag.base04};
|
||||
}
|
||||
#cpu,
|
||||
#memory {
|
||||
color: ${withHashtag.base04};
|
||||
}
|
||||
|
||||
#mpris {
|
||||
font-size: 10pt;
|
||||
margin-right: 6px;
|
||||
}
|
||||
#mpris {
|
||||
font-size: 10pt;
|
||||
margin-right: 6px;
|
||||
}
|
||||
|
||||
#tray {
|
||||
padding: 0 5px;
|
||||
background-color: ${withHashtag.base02};
|
||||
}
|
||||
#tray {
|
||||
padding: 0 5px;
|
||||
background-color: ${withHashtag.base02};
|
||||
}
|
||||
|
||||
#pulseaudio {
|
||||
color: ${withHashtag.base0D};
|
||||
}
|
||||
#pulseaudio {
|
||||
color: ${withHashtag.base0D};
|
||||
}
|
||||
|
||||
#network {
|
||||
color: ${withHashtag.base0C};
|
||||
}
|
||||
#network {
|
||||
color: ${withHashtag.base0C};
|
||||
}
|
||||
|
||||
#language {
|
||||
color: ${withHashtag.base02};
|
||||
margin-left: 10px;
|
||||
}
|
||||
'';
|
||||
#language {
|
||||
color: ${withHashtag.base02};
|
||||
margin-left: 10px;
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ config, lib, ... }: {
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
programs.wofi = {
|
||||
enable = true;
|
||||
settings = {
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./mise.nix
|
||||
./php.nix
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
python3 # needed for installing node.js
|
||||
];
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
# install php from nixpkgs because mise wants to compile it from source,
|
||||
# and that's a whole can of beans i'm not getting into
|
||||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
php83
|
||||
];
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
xivlauncher
|
||||
];
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
{ lib, config, pkgs, ... }:
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
../../common/desktop
|
||||
|
@ -100,101 +105,109 @@
|
|||
"SUPER,mouse:273,resizewindow"
|
||||
];
|
||||
|
||||
bind = let
|
||||
terminal = "${pkgs.alacritty}/bin/alacritty";
|
||||
grimblast = lib.getExe pkgs.grimblast;
|
||||
workspaces = [
|
||||
"1"
|
||||
"2"
|
||||
"3"
|
||||
"4"
|
||||
"5"
|
||||
];
|
||||
directions = rec {
|
||||
left = "l";
|
||||
right = "r";
|
||||
up = "u";
|
||||
down = "d";
|
||||
h = left;
|
||||
l = right;
|
||||
k = up;
|
||||
j = down;
|
||||
};
|
||||
in [
|
||||
"SUPER,Return,exec,${terminal}"
|
||||
"SUPERSHIFT,q,killactive" # exit program
|
||||
"SUPERSHIFT,e,exit" # exit hyprland
|
||||
"SUPERSHIFT,r,exec,hyprctl reload" # reload currently running hyprland
|
||||
|
||||
"SUPER,s,togglesplit" # horizontal split
|
||||
"SUPER,f,fullscreen,1" # borderless window
|
||||
"SUPERSHIFT,f,fullscreen,0" # proper fullscreen
|
||||
"ALTSHIFT,space,togglefloating" # floating window
|
||||
|
||||
"SUPER,minus,splitratio,-0.25" # split gets slightly smaller
|
||||
"SUPERSHIFT,minus,splitratio,-0.3333333" # split gets smaller
|
||||
"SUPER,equal,splitratio,0.25" # split gets slightly larger
|
||||
"SUPERSHIFT,equal,splitratio,0.3333333" # split gets larger
|
||||
|
||||
"SUPER,g,togglegroup" # make a window group
|
||||
"SUPER,t,lockactivegroup,toggle" # lock/unlock the current group
|
||||
"SUPER,tab,changegroupactive,f" # switch to next window in group
|
||||
"SUPERSHIFT,tab,changegroupactive,p" # switch to prev window in group
|
||||
|
||||
"SUPER,dead_grave,workspace,previous" # prev workspace
|
||||
"SUPER,dead_grave,workspace,next" # next workspace
|
||||
|
||||
"SUPER,u,togglespecialworkspace" # toggle special workspace
|
||||
"SUPERSHIFT,u,movetoworkspacesilent,special" # move to special workspace
|
||||
|
||||
",Print,exec,${grimblast} --notify --freeze copy area" # screenshot area
|
||||
"SHIFT,Print,exec,${grimblast} --notify --freeze copy output" # screenshot all
|
||||
|
||||
",XF86AudioRaiseVolume,exec,pamixer -i 5" # raise volume
|
||||
",XF86AudioLowerVolume,exec,pamixer -d 5" # lower volume
|
||||
",XF86AudioPlay,exec,playerctl play-pause" # play/pause
|
||||
",XF86AudioNext,exec,playerctl next" # next song
|
||||
",XF86AudioPrev,exec,playerctl previous" # previous song
|
||||
]
|
||||
++
|
||||
# change workspace
|
||||
(map (n: "SUPER,${n},workspace,name:${n}") workspaces)
|
||||
++
|
||||
# move window to workspace
|
||||
(map (n: "SUPERSHIFT,${n},movetoworkspacesilent,name:${n}") workspaces)
|
||||
++
|
||||
# move focus
|
||||
(lib.mapAttrsToList (key: direction: "SUPER,${key},movefocus,${direction}") directions)
|
||||
++
|
||||
# swap windows
|
||||
(lib.mapAttrsToList (key: direction: "SUPERSHIFT,${key},swapwindow,${direction}") directions)
|
||||
++
|
||||
# move windows
|
||||
(lib.mapAttrsToList (key: direction: "SUPERCONTROL,${key},movewindoworgroup,${direction}") directions)
|
||||
++
|
||||
# move monitor focus
|
||||
(lib.mapAttrsToList (key: direction: "SUPERALT,${key},focusmonitor,${direction}") directions)
|
||||
++
|
||||
# move workspace to other monitor
|
||||
(lib.mapAttrsToList (key: direction: "SUPERALTSHIFT,${key},movecurrentworkspacetomonitor,${direction}") directions)
|
||||
++
|
||||
# launcher
|
||||
(
|
||||
bind =
|
||||
let
|
||||
wofi = lib.getExe pkgs.wofi;
|
||||
in
|
||||
lib.optionals config.programs.wofi.enable [
|
||||
"SUPER,Space,exec,${wofi} -S drun -W 20% -H 15%"
|
||||
"SHIFTSUPER,Space,exec,${wofi} -S run -W 20% -H 15%"
|
||||
]
|
||||
);
|
||||
terminal = "${pkgs.alacritty}/bin/alacritty";
|
||||
grimblast = lib.getExe pkgs.grimblast;
|
||||
workspaces = [
|
||||
"1"
|
||||
"2"
|
||||
"3"
|
||||
"4"
|
||||
"5"
|
||||
];
|
||||
directions = rec {
|
||||
left = "l";
|
||||
right = "r";
|
||||
up = "u";
|
||||
down = "d";
|
||||
h = left;
|
||||
l = right;
|
||||
k = up;
|
||||
j = down;
|
||||
};
|
||||
in
|
||||
[
|
||||
"SUPER,Return,exec,${terminal}"
|
||||
"SUPERSHIFT,q,killactive" # exit program
|
||||
"SUPERSHIFT,e,exit" # exit hyprland
|
||||
"SUPERSHIFT,r,exec,hyprctl reload" # reload currently running hyprland
|
||||
|
||||
"SUPER,s,togglesplit" # horizontal split
|
||||
"SUPER,f,fullscreen,1" # borderless window
|
||||
"SUPERSHIFT,f,fullscreen,0" # proper fullscreen
|
||||
"ALTSHIFT,space,togglefloating" # floating window
|
||||
|
||||
"SUPER,minus,splitratio,-0.25" # split gets slightly smaller
|
||||
"SUPERSHIFT,minus,splitratio,-0.3333333" # split gets smaller
|
||||
"SUPER,equal,splitratio,0.25" # split gets slightly larger
|
||||
"SUPERSHIFT,equal,splitratio,0.3333333" # split gets larger
|
||||
|
||||
"SUPER,g,togglegroup" # make a window group
|
||||
"SUPER,t,lockactivegroup,toggle" # lock/unlock the current group
|
||||
"SUPER,tab,changegroupactive,f" # switch to next window in group
|
||||
"SUPERSHIFT,tab,changegroupactive,p" # switch to prev window in group
|
||||
|
||||
"SUPER,dead_grave,workspace,previous" # prev workspace
|
||||
"SUPER,dead_grave,workspace,next" # next workspace
|
||||
|
||||
"SUPER,u,togglespecialworkspace" # toggle special workspace
|
||||
"SUPERSHIFT,u,movetoworkspacesilent,special" # move to special workspace
|
||||
|
||||
",Print,exec,${grimblast} --notify --freeze copy area" # screenshot area
|
||||
"SHIFT,Print,exec,${grimblast} --notify --freeze copy output" # screenshot all
|
||||
|
||||
",XF86AudioRaiseVolume,exec,pamixer -i 5" # raise volume
|
||||
",XF86AudioLowerVolume,exec,pamixer -d 5" # lower volume
|
||||
",XF86AudioPlay,exec,playerctl play-pause" # play/pause
|
||||
",XF86AudioNext,exec,playerctl next" # next song
|
||||
",XF86AudioPrev,exec,playerctl previous" # previous song
|
||||
]
|
||||
++
|
||||
# change workspace
|
||||
(map (n: "SUPER,${n},workspace,name:${n}") workspaces)
|
||||
++
|
||||
# move window to workspace
|
||||
(map (n: "SUPERSHIFT,${n},movetoworkspacesilent,name:${n}") workspaces)
|
||||
++
|
||||
# move focus
|
||||
(lib.mapAttrsToList (key: direction: "SUPER,${key},movefocus,${direction}") directions)
|
||||
++
|
||||
# swap windows
|
||||
(lib.mapAttrsToList (key: direction: "SUPERSHIFT,${key},swapwindow,${direction}") directions)
|
||||
++
|
||||
# move windows
|
||||
(lib.mapAttrsToList (
|
||||
key: direction: "SUPERCONTROL,${key},movewindoworgroup,${direction}"
|
||||
) directions)
|
||||
++
|
||||
# move monitor focus
|
||||
(lib.mapAttrsToList (key: direction: "SUPERALT,${key},focusmonitor,${direction}") directions)
|
||||
++
|
||||
# move workspace to other monitor
|
||||
(lib.mapAttrsToList (
|
||||
key: direction: "SUPERALTSHIFT,${key},movecurrentworkspacetomonitor,${direction}"
|
||||
) directions)
|
||||
++
|
||||
# launcher
|
||||
(
|
||||
let
|
||||
wofi = lib.getExe pkgs.wofi;
|
||||
in
|
||||
lib.optionals config.programs.wofi.enable [
|
||||
"SUPER,Space,exec,${wofi} -S drun -W 20% -H 15%"
|
||||
"SHIFTSUPER,Space,exec,${wofi} -S run -W 20% -H 15%"
|
||||
]
|
||||
);
|
||||
|
||||
monitor = map (
|
||||
m: "${m.name},${
|
||||
if m.enabled
|
||||
then "${toString m.width}x${toString m.height}@${toString m.refreshRate},${m.position},${m.scale}"
|
||||
else "disable"
|
||||
}"
|
||||
m:
|
||||
"${m.name},${
|
||||
if m.enabled then
|
||||
"${toString m.width}x${toString m.height}@${toString m.refreshRate},${m.position},${m.scale}"
|
||||
else
|
||||
"disable"
|
||||
}"
|
||||
) config.monitors;
|
||||
|
||||
workspace = map (m: "name:${m.workspace},monitor:${m.name}") (
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
{ config, ... }: let
|
||||
{ config, ... }:
|
||||
let
|
||||
swaylock = "${config.programs.swaylock.package}/bin/swaylock";
|
||||
in {
|
||||
in
|
||||
{
|
||||
services.swayidle = {
|
||||
enable = true;
|
||||
systemdTarget = "graphical-session.target";
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
programs.swaylock = {
|
||||
enable = true;
|
||||
package = pkgs.swaylock-effects;
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
# enoko is my framework 13-inch AMD laptop, running nixos
|
||||
{ ... }: {
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./global.nix
|
||||
./common/desktop
|
||||
|
|
|
@ -1,4 +1,12 @@
|
|||
{ inputs, lib, pkgs, config, outputs, ... }: {
|
||||
{
|
||||
inputs,
|
||||
lib,
|
||||
pkgs,
|
||||
config,
|
||||
outputs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
inputs.nix-index-database.hmModules.nix-index
|
||||
inputs.stylix.homeManagerModules.stylix
|
||||
|
@ -17,13 +25,16 @@
|
|||
nix = {
|
||||
package = lib.mkDefault pkgs.nixVersions.nix_2_22;
|
||||
settings = {
|
||||
experimental-features = ["nix-command" "flakes"];
|
||||
experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
warn-dirty = false;
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user.startServices = "sd-switch";
|
||||
|
||||
|
||||
programs = {
|
||||
home-manager.enable = true;
|
||||
};
|
||||
|
@ -38,7 +49,7 @@
|
|||
username = lib.mkDefault "lu";
|
||||
homeDirectory = lib.mkDefault "/home/${config.home.username}";
|
||||
stateVersion = lib.mkDefault "24.05";
|
||||
sessionPath = ["$HOME/.local/bin"];
|
||||
sessionPath = [ "$HOME/.local/bin" ];
|
||||
sessionVariables = {
|
||||
FLAKE = "$HOME/nix-config";
|
||||
};
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
# yukari my main desktop workstation, running nixos
|
||||
{ ... }: {
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./global.nix
|
||||
./desktop/hyprland
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue