added home/hyprland.nix, adjusted core/default & core/display.nix
This commit is contained in:
parent
700e6e31cf
commit
8031d9027c
4 changed files with 67 additions and 29 deletions
|
|
@ -4,12 +4,7 @@
|
||||||
inputs = {
|
inputs = {
|
||||||
|
|
||||||
# Nixpkgs and hardware specific configs
|
# Nixpkgs and hardware specific configs
|
||||||
|
|
||||||
# there was a way to have unstable as an overlay,
|
|
||||||
# will set it back up, lazy rn, for now pick one
|
|
||||||
# nixpkgs.url = "nixpkgs/nixos-23.11";
|
|
||||||
nixpkgs.url = "nixpkgs/nixos-unstable";
|
nixpkgs.url = "nixpkgs/nixos-unstable";
|
||||||
|
|
||||||
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
||||||
|
|
||||||
# declarative disks
|
# declarative disks
|
||||||
|
|
@ -18,16 +13,18 @@
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# declarative dots
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# ricer friendly wayland compositor
|
||||||
hyprland.url = "github:hyprwm/Hyprland";
|
hyprland.url = "github:hyprwm/Hyprland";
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { nixpkgs, nixos-hardware, disko, home-manager, hyprland, ... }: {
|
outputs = { nixpkgs, nixos-hardware, disko, home-manager, ... }: {
|
||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
proserpina = nixpkgs.lib.nixosSystem {
|
proserpina = nixpkgs.lib.nixosSystem {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,12 @@
|
||||||
{ inputs, pkgs, username, ... }:
|
{ pkgs, lib, inputs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
|
|
||||||
programs.hyprland = {
|
programs.hyprland = {
|
||||||
enable = true;
|
enable = true;
|
||||||
xwayland.enable = true;
|
xwayland.enable = true;
|
||||||
|
packages = inputs.hyprland.packages."${pkgs.system}"
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
xdg.portal = {
|
xdg.portal = {
|
||||||
|
|
@ -17,22 +19,22 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
services.xserver = {
|
# services.xserver = {
|
||||||
enable = true;
|
# enable = true;
|
||||||
layout = "us"; # what is the difference #
|
# layout = "us"; # what is the difference #
|
||||||
xkbVariant = ""; # between
|
# xkbVariant = ""; # between
|
||||||
xkb.layout = "us"; # these 2 lolwut #
|
# xkb.layout = "us"; # these 2 lolwut #
|
||||||
displayManager.autoLogin = {
|
# displayManager.autoLogin = {
|
||||||
enable = true;
|
# enable = true;
|
||||||
user = "serenity";
|
# user = "serenity";
|
||||||
};
|
# };
|
||||||
libinput = {
|
# libinput = {
|
||||||
enable = true;
|
# enable = true;
|
||||||
mouse = {
|
# mouse = {
|
||||||
accelProfile = "flat";
|
# accelProfile = "flat";
|
||||||
};
|
# };
|
||||||
};
|
# };
|
||||||
};
|
# };
|
||||||
|
|
||||||
# apparently prevents getting stuck at shutdown
|
# apparently prevents getting stuck at shutdown
|
||||||
systemd.extraConfig = "DefaultTimeoutStopSec=10s";
|
systemd.extraConfig = "DefaultTimeoutStopSec=10s";
|
||||||
|
|
|
||||||
|
|
@ -1,5 +0,0 @@
|
||||||
{
|
|
||||||
|
|
||||||
wayland.windowManager.hyprland.enable = true;
|
|
||||||
|
|
||||||
}
|
|
||||||
44
modules/home/hyprland.nix
Normal file
44
modules/home/hyprland.nix
Normal file
|
|
@ -0,0 +1,44 @@
|
||||||
|
{ pkgs, lib, config, inputs, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
startupScript = pkgs.pkgs.writeShellScriptBin "start" ''
|
||||||
|
${pkgs.waybar}/bin/waybar &
|
||||||
|
${pkgs.swww}/bin/swww init &
|
||||||
|
|
||||||
|
sleep 1
|
||||||
|
|
||||||
|
${pkgs.swww}/bin/swww img ${./wallpaper.png} &
|
||||||
|
'';
|
||||||
|
in
|
||||||
|
{
|
||||||
|
|
||||||
|
wayland.windowManager.hyprland = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
plugins = [
|
||||||
|
inputs.hyprland-plugins.packages."${pkgs.system}".borders-plus-plus
|
||||||
|
];
|
||||||
|
|
||||||
|
settings = {
|
||||||
|
|
||||||
|
exec-once = ''${startupScript}/bin/start'';
|
||||||
|
|
||||||
|
"plugin:borders-plus-plus" = {
|
||||||
|
add_borders = 1; # 0 - 9
|
||||||
|
|
||||||
|
# you can add up to 9 borders
|
||||||
|
"col.border_1" = "rgb(ffffff)";
|
||||||
|
"col.border_2" = "rgb(2222ff)";
|
||||||
|
|
||||||
|
# -1 means "default" as in the one defined in general:border_size
|
||||||
|
border_size_1 = 10;
|
||||||
|
border_size_2 = -1;
|
||||||
|
|
||||||
|
# makes outer edges match rounding of the parent. Turn on / off to better understand. Default = on.
|
||||||
|
natural_rounding = "yes";
|
||||||
|
};
|
||||||
|
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue