fix some hyprland stuff
This commit is contained in:
@@ -202,6 +202,15 @@
|
||||
nixos-raspberrypi.lib.inject-overlays
|
||||
];
|
||||
};
|
||||
|
||||
# ######################################################
|
||||
# Mac #
|
||||
# ######################################################
|
||||
macbook-pro-nixos = {
|
||||
modules = with inputs; [
|
||||
nixos-apple-silicon.nixosModules.default
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
overlays = with inputs; [ nix-vscode-extensions.overlays.default ];
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
{ pkgs, ... }:
|
||||
let
|
||||
shellAliases = {
|
||||
update-boot = "sudo nixos-rebuild boot --max-jobs 10 --build-host admin@10.0.1.3";
|
||||
update-switch = "sudo nixos-rebuild switch --max-jobs 10 --build-host admin@10.0.1.3";
|
||||
update-flake = "nix flake update mac-nixpkgs mac-nixos-apple-silicon mac-home-manager mac-impermanence mac-sops-nix --flake /etc/nixos";
|
||||
update-nas = "nixos-rebuild switch --use-remote-sudo --target-host admin@10.0.1.3 --build-host admin@10.0.1.3 --flake ~/nix-config#jallen-nas";
|
||||
};
|
||||
in
|
||||
{
|
||||
|
||||
home.username = "matt";
|
||||
home.homeDirectory = "/home/matt";
|
||||
home.stateVersion = "23.11";
|
||||
|
||||
home.packages = with pkgs; [
|
||||
iw
|
||||
iwd
|
||||
orca-slicer
|
||||
vscodium
|
||||
];
|
||||
|
||||
programs = {
|
||||
password-store.enable = true;
|
||||
|
||||
zsh.shellAliases = shellAliases;
|
||||
};
|
||||
}
|
||||
134
homes/aarch64-linux/matt@macbook-pro-nixos/default.nix
Executable file
134
homes/aarch64-linux/matt@macbook-pro-nixos/default.nix
Executable file
@@ -0,0 +1,134 @@
|
||||
{ pkgs, lib, ... }:
|
||||
let
|
||||
theme = import (lib.snowfall.fs.get-file "modules/home/desktop/theme/nord.nix");
|
||||
shellAliases = {
|
||||
update-boot = "sudo nixos-rebuild boot --max-jobs 10 --build-host admin@10.0.1.3";
|
||||
update-switch = "sudo nixos-rebuild switch --max-jobs 10 --build-host admin@10.0.1.3";
|
||||
update-flake = "nix flake update mac-nixpkgs mac-nixos-apple-silicon mac-home-manager mac-impermanence mac-sops-nix --flake /etc/nixos";
|
||||
update-nas = "nixos-rebuild switch --use-remote-sudo --target-host admin@10.0.1.3 --build-host admin@10.0.1.3 --flake ~/nix-config#jallen-nas";
|
||||
};
|
||||
fontName = "JetBrainsMono NFM";
|
||||
fontPackage = pkgs.nerd-fonts.jetbrains-mono;
|
||||
# Displays
|
||||
display = {
|
||||
input = "eDP-1";
|
||||
resolution = "3456x2234";
|
||||
refreshRate = "60.00000";
|
||||
};
|
||||
in
|
||||
{
|
||||
|
||||
home.username = "matt";
|
||||
home.homeDirectory = "/home/matt";
|
||||
home.stateVersion = "23.11";
|
||||
|
||||
mjallen = {
|
||||
desktop.hyprland = {
|
||||
enable = true;
|
||||
primaryDisplay = "eDP-1";
|
||||
|
||||
wallpaper = [
|
||||
"${display.input}, /run/wallpaper.jpg"
|
||||
];
|
||||
|
||||
monitor = [
|
||||
"${display.input},${display.resolution}@${display.refreshRate},0x0,1.25,bitdepth,10,cm,hdr,sdrbrightness,1.2,sdrsaturation,0.98"
|
||||
];
|
||||
|
||||
workspace = [
|
||||
"name:firefox, monitor:${display.input}, default:false, special, class:(.*firefox.*)"
|
||||
"name:discord, monitor:${display.input}, default:true, special, title:(.*vesktop.*), title:(.*Apple Music.*)"
|
||||
"name:steam, monitor:${display.input}, default:false, special, class:(.*[Ss]team.*)"
|
||||
];
|
||||
|
||||
|
||||
windowRule = [
|
||||
"size 2160 3356, tag:horizonrdp"
|
||||
];
|
||||
defaultApps = {
|
||||
browser = pkgs.firefox;
|
||||
};
|
||||
};
|
||||
programs = {
|
||||
btop.enable = true;
|
||||
kitty = {
|
||||
enable = true;
|
||||
font = {
|
||||
name = fontName;
|
||||
package = fontPackage;
|
||||
};
|
||||
};
|
||||
mako = {
|
||||
enable = true;
|
||||
fontName = fontName;
|
||||
};
|
||||
nwg-dock.enable = true;
|
||||
nwg-drawer.enable = true;
|
||||
nwg-panel = {
|
||||
enable = true;
|
||||
defaultApps = {
|
||||
browser = pkgs.firefox;
|
||||
};
|
||||
};
|
||||
waybar = {
|
||||
enable = true;
|
||||
|
||||
layer = "bottom";
|
||||
|
||||
modules-right = [
|
||||
"tray"
|
||||
"temperature"
|
||||
"temperature#gpu"
|
||||
"keyboard-state#capslock"
|
||||
"keyboard-state#numlock"
|
||||
"wireplumber#sink"
|
||||
"bluetooth"
|
||||
"network"
|
||||
"idle_inhibitor"
|
||||
"clock"
|
||||
"battery"
|
||||
"custom/weather"
|
||||
];
|
||||
|
||||
extraModules = {
|
||||
"custom/lights" = {
|
||||
tooltip = false;
|
||||
exec = "waybar-hass --get_light light.living_room_lights";
|
||||
interval = "once";
|
||||
format = "{text}";#"";
|
||||
on-click = "waybar-hass --toggle_light light.living_room_lights";
|
||||
return-type = "json";
|
||||
};
|
||||
};
|
||||
|
||||
extraModulesStyle = ''
|
||||
#custom-lights {
|
||||
color: ${theme.frost.nord8};
|
||||
background-color: ${theme.polarNight.nord0};
|
||||
${theme.defaultOpacity}
|
||||
${theme.borderLeft}
|
||||
}
|
||||
|
||||
#custom-lights:hover {
|
||||
background: ${theme.polarNight.nord3};
|
||||
}
|
||||
'';
|
||||
};
|
||||
wlogout.enable = true;
|
||||
wofi.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [
|
||||
iw
|
||||
iwd
|
||||
orca-slicer
|
||||
vscodium
|
||||
];
|
||||
|
||||
programs = {
|
||||
password-store.enable = true;
|
||||
|
||||
zsh.shellAliases = shellAliases;
|
||||
};
|
||||
}
|
||||
@@ -145,7 +145,7 @@ in
|
||||
"$mod, XF86MonBrightnessDown, exec, brightnessctl -d kbd_backlight set 10%-"
|
||||
];
|
||||
|
||||
monitor = cfg.monitor or [ ];
|
||||
monitor = cfg.monitor;
|
||||
monitorv2 = cfg.monitorv2 or { };
|
||||
|
||||
render = {
|
||||
|
||||
@@ -20,7 +20,7 @@ with lib;
|
||||
default = "3840x2160";
|
||||
};
|
||||
|
||||
refreshRate = mkOptions {
|
||||
refreshRate = mkOption {
|
||||
type = types.str;
|
||||
default = "240.00000";
|
||||
};
|
||||
@@ -37,7 +37,7 @@ with lib;
|
||||
default = "3840x2160";
|
||||
};
|
||||
|
||||
refreshRate = mkOptions {
|
||||
refreshRate = mkOption {
|
||||
type = types.str;
|
||||
default = "240.00000";
|
||||
};
|
||||
@@ -99,7 +99,7 @@ with lib;
|
||||
terminal = mkOption { type = types.package; default = pkgs.kitty; };
|
||||
office = mkOption { type = types.package; default = pkgs.onlyoffice-bin_latest; };
|
||||
video = mkOption { type = types.package; default = pkgs.vlc; };
|
||||
imageViewer = mkOption { type = types.package; default = pkgs.gnome-photos; };
|
||||
imageViewer = mkOption { type = types.package; default = pkgs.nomacs; };
|
||||
};
|
||||
};
|
||||
description = "Default applications used across the system.";
|
||||
|
||||
@@ -37,6 +37,7 @@ in
|
||||
nautilus
|
||||
networkmanagerapplet
|
||||
nm-tray
|
||||
nomacs
|
||||
nwg-look
|
||||
overskride
|
||||
pamixer
|
||||
|
||||
@@ -7,7 +7,7 @@ in
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
services.hypridle = {
|
||||
enable = true;
|
||||
enable = false;
|
||||
settings = {
|
||||
general = {
|
||||
before_sleep_cmd = "loginctl lock-session"; # lock before suspend.
|
||||
@@ -38,4 +38,4 @@ in
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ in
|
||||
enable = true;
|
||||
settings = {
|
||||
preload = [ "/run/wallpaper.jpg" ];
|
||||
wallpaper = "/run/wallpaper.jpg";
|
||||
wallpaper = ",/run/wallpaper.jpg";
|
||||
splash = false;
|
||||
};
|
||||
};
|
||||
|
||||
@@ -103,5 +103,9 @@
|
||||
services = {
|
||||
nextcloud-client.enable = lib.mkDefault true;
|
||||
pass-secret-service.enable = lib.mkDefault true;
|
||||
kdeconnect = {
|
||||
enable = true;
|
||||
indicator = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -371,8 +371,8 @@ in
|
||||
${defaultOpacity}
|
||||
${defaultBorderRadius}
|
||||
${defaultCenterOptions}
|
||||
margin-left: 4rem
|
||||
margin-right: 4rem
|
||||
margin-left: 4rem;
|
||||
margin-right: 4rem;
|
||||
}
|
||||
|
||||
/* make window module transparent when no windows present */
|
||||
|
||||
@@ -109,7 +109,7 @@ in
|
||||
];
|
||||
script = ''
|
||||
bing-wallpaper
|
||||
${pkgs.hyprland}/bin/hyprctl hyprpaper reload ,/run/wallpaper
|
||||
${pkgs.hyprland}/bin/hyprctl hyprpaper reload ,/run/wallpaper.jpg
|
||||
'';
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
|
||||
@@ -101,7 +101,7 @@ in
|
||||
terminal = pkgs.kitty;
|
||||
office = pkgs.onlyoffice-bin_latest;
|
||||
video = pkgs.vlc;
|
||||
imageViewer = pkgs.gnome-photos;
|
||||
imageViewer = pkgs.nomacs;
|
||||
};
|
||||
|
||||
theme = nord;
|
||||
|
||||
@@ -40,81 +40,90 @@ in
|
||||
networking = {
|
||||
hostName = lib.mkForce cfg.hostName;
|
||||
|
||||
# Enable Network Manager
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.powersave = lib.mkDefault false;
|
||||
settings.connectivity.uri = lib.mkDefault "http://nmcheck.gnome.org/check_network_status.txt";
|
||||
ensureProfiles = {
|
||||
environmentFiles = [
|
||||
config.sops.secrets.wifi.path
|
||||
];
|
||||
# Enable Network Manager
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.powersave = lib.mkDefault false;
|
||||
settings.connectivity.uri = lib.mkDefault "http://nmcheck.gnome.org/check_network_status.txt";
|
||||
ensureProfiles = {
|
||||
environmentFiles = [
|
||||
config.sops.secrets.wifi.path
|
||||
];
|
||||
|
||||
profiles = {
|
||||
"Joey's Jungle 6G" = {
|
||||
connection = {
|
||||
id = "Joey's Jungle 6G";
|
||||
type = "wifi";
|
||||
profiles = {
|
||||
"Joey's Jungle 6G" = {
|
||||
connection = {
|
||||
id = "Joey's Jungle 6G";
|
||||
type = "wifi";
|
||||
};
|
||||
ipv4 = if (cfg.ipv4.method == "auto")
|
||||
then
|
||||
{
|
||||
method = "auto";
|
||||
}
|
||||
else
|
||||
{
|
||||
address1 = cfg.ipv4.address;
|
||||
dns = cfg.ipv4.dns;
|
||||
gateway = cfg.ipv4.gateway;
|
||||
method = "manual";
|
||||
};
|
||||
ipv6 = {
|
||||
addr-gen-mode = "stable-privacy";
|
||||
method = "auto";
|
||||
};
|
||||
wifi = {
|
||||
mode = "infrastructure";
|
||||
ssid = "Joey's Jungle 6G";
|
||||
};
|
||||
wifi-security = {
|
||||
key-mgmt = "sae";
|
||||
psk = "$PSK";
|
||||
};
|
||||
};
|
||||
ipv4 = if (cfg.ipv4.method == "auto")
|
||||
then
|
||||
{
|
||||
method = "auto";
|
||||
}
|
||||
else
|
||||
{
|
||||
address1 = cfg.ipv4.address;
|
||||
dns = cfg.ipv4.dns;
|
||||
gateway = cfg.ipv4.gateway;
|
||||
method = "manual";
|
||||
};
|
||||
ipv6 = {
|
||||
addr-gen-mode = "stable-privacy";
|
||||
method = "auto";
|
||||
};
|
||||
wifi = {
|
||||
mode = "infrastructure";
|
||||
ssid = "Joey's Jungle 6G";
|
||||
};
|
||||
wifi-security = {
|
||||
key-mgmt = "sae";
|
||||
psk = "$PSK";
|
||||
};
|
||||
};
|
||||
|
||||
"Joey's Jungle 5G" = {
|
||||
connection = {
|
||||
id = "Joey's Jungle 5G";
|
||||
type = "wifi";
|
||||
};
|
||||
ipv4 = if (cfg.ipv4.method == "auto")
|
||||
then
|
||||
{
|
||||
method = "auto";
|
||||
}
|
||||
else
|
||||
{
|
||||
address1 = cfg.ipv4.address;
|
||||
dns = cfg.ipv4.dns;
|
||||
gateway = cfg.ipv4.gateway;
|
||||
method = "manual";
|
||||
};
|
||||
ipv6 = {
|
||||
addr-gen-mode = "stable-privacy";
|
||||
method = "auto";
|
||||
};
|
||||
wifi = {
|
||||
mode = "infrastructure";
|
||||
ssid = "Joey's Jungle 5G";
|
||||
};
|
||||
wifi-security = {
|
||||
key-mgmt = "sae";
|
||||
psk = "$PSK";
|
||||
"Joey's Jungle 5G" = {
|
||||
connection = {
|
||||
id = "Joey's Jungle 5G";
|
||||
type = "wifi";
|
||||
};
|
||||
ipv4 = if (cfg.ipv4.method == "auto")
|
||||
then
|
||||
{
|
||||
method = "auto";
|
||||
}
|
||||
else
|
||||
{
|
||||
address1 = cfg.ipv4.address;
|
||||
dns = cfg.ipv4.dns;
|
||||
gateway = cfg.ipv4.gateway;
|
||||
method = "manual";
|
||||
};
|
||||
ipv6 = {
|
||||
addr-gen-mode = "stable-privacy";
|
||||
method = "auto";
|
||||
};
|
||||
wifi = {
|
||||
mode = "infrastructure";
|
||||
ssid = "Joey's Jungle 5G";
|
||||
};
|
||||
wifi-security = {
|
||||
key-mgmt = "sae";
|
||||
psk = "$PSK";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
firewall = {
|
||||
allowedTCPPortRanges = [
|
||||
{
|
||||
from = 1714;
|
||||
to = 1764;
|
||||
}
|
||||
];
|
||||
allowedUDPPortRanges = config.networking.firewall.allowedTCPPortRanges;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -4,7 +4,7 @@
|
||||
boot = {
|
||||
loader = {
|
||||
systemd-boot = {
|
||||
enable = true;
|
||||
enable = lib.mkForce true;
|
||||
configurationLimit = 15;
|
||||
consoleMode = lib.mkDefault "max";
|
||||
};
|
||||
@@ -2,9 +2,15 @@
|
||||
# your system. Help is available in the configuration.nix(5) man page, on
|
||||
# https://search.nixos.org/options and in the NixOS manual (`nixos-help`).
|
||||
|
||||
{ pkgs, lib, ... }:
|
||||
{ pkgs, lib, namespace, ... }:
|
||||
let
|
||||
plasma = false;
|
||||
# Displays
|
||||
display = {
|
||||
input = "eDP-1";
|
||||
resolution = "3456x2234";
|
||||
refreshRate = "60.00000";
|
||||
};
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
@@ -21,9 +27,43 @@ in
|
||||
setupAsahiSound = true;
|
||||
};
|
||||
|
||||
hardware.graphics.enable32Bit = lib.mkForce false;
|
||||
${namespace} = {
|
||||
desktop = {
|
||||
hyprland = {
|
||||
enable = true;
|
||||
primaryDisplay = "eDP-1";
|
||||
|
||||
display1 = {
|
||||
input = "eDP-1";
|
||||
resolution = "3456x2234";
|
||||
refreshRate = "60.00000";
|
||||
};
|
||||
|
||||
wallpaper = [
|
||||
"${display.input}, /run/wallpaper.jpg"
|
||||
];
|
||||
|
||||
monitor = [
|
||||
"${display.input},${display.resolution}@${display.refreshRate},0x0,1.25,bitdepth,10,cm,hdr,sdrbrightness,1.2,sdrsaturation,0.98"
|
||||
];
|
||||
|
||||
workspace = [
|
||||
"name:firefox, monitor:${display.input}, default:false, special, class:(.*firefox.*)"
|
||||
"name:discord, monitor:${display.input}, default:true, special, title:(.*vesktop.*), title:(.*Apple Music.*)"
|
||||
"name:steam, monitor:${display.input}, default:false, special, class:(.*[Ss]team.*)"
|
||||
];
|
||||
|
||||
|
||||
windowRule = [
|
||||
"size 2160 3356, tag:horizonrdp"
|
||||
];
|
||||
};
|
||||
};
|
||||
network = {
|
||||
hostName = "macbook-pro-nixos";
|
||||
};
|
||||
};
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
nixpkgs.config.allowUnsupportedSystem = true;
|
||||
|
||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||
@@ -59,12 +99,20 @@ in
|
||||
# List packages installed in system profile. To search, run:
|
||||
# $ nix search wget
|
||||
environment.systemPackages = with pkgs; [
|
||||
aria
|
||||
asahi-bless
|
||||
asahi-btsync
|
||||
asahi-nvram
|
||||
asahi-wifisync
|
||||
cabextract
|
||||
micro
|
||||
unzip
|
||||
vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
|
||||
wget
|
||||
];
|
||||
|
||||
environment.sessionVariables = {
|
||||
DBX_CONTAINER_MANAGER = "podman";
|
||||
GSK_RENDERER = "opengl";
|
||||
};
|
||||
}
|
||||
@@ -60,12 +60,12 @@
|
||||
options = [ "fmask=0022" "dmask=0022" ];
|
||||
};
|
||||
|
||||
swapDevices = [
|
||||
{
|
||||
device = "/tmp/swapfile";
|
||||
randomEncryption.enable = true;
|
||||
}
|
||||
];
|
||||
# swapDevices = [
|
||||
# {
|
||||
# device = "/tmp/swapfile";
|
||||
# randomEncryption.enable = true;
|
||||
# }
|
||||
# ];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
@@ -8,19 +8,18 @@
|
||||
charger = {
|
||||
# see available governors by running: cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
|
||||
# preferred governor
|
||||
governor = "performance";
|
||||
governor = "schedutil";
|
||||
|
||||
# minimum cpu frequency (in kHz)
|
||||
# example: for 800 MHz = 800000 kHz --> scaling_min_freq = 800000
|
||||
# Available: 912 MHz, 1284 MHz, 1752 MHz, 2004 MHz, 2256 MHz, 2424 MHz
|
||||
# 702000 948000 1188000 1452000 1704000 1968000 2208000 2400000 2568000 2724000 2868000 3000000 3132000 3264000
|
||||
# see conversion info: https://www.rapidtables.com/convert/frequency/mhz-to-hz.html
|
||||
# to use this feature, uncomment the following line and set the value accordingly
|
||||
# scaling_min_freq = 800000
|
||||
|
||||
# maximum cpu frequency (in kHz)
|
||||
# example: for 1GHz = 1000 MHz = 1000000 kHz -> scaling_max_freq = 1000000
|
||||
# see conversion info: https://www.rapidtables.com/convert/frequency/mhz-to-hz.html
|
||||
# to use this feature, uncomment the following line and set the value accordingly
|
||||
# scaling_max_freq = 1000000
|
||||
scaling_min_freq = 912000;
|
||||
scaling_max_freq = 2424000;
|
||||
# scaling_min_freq = 702000;
|
||||
# scaling_max_freq = 1968000;
|
||||
|
||||
# turbo boost setting. possible values: always, auto, never
|
||||
turbo = "auto";
|
||||
@@ -29,19 +28,16 @@
|
||||
battery = {
|
||||
# see available governors by running: cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
|
||||
# preferred governor
|
||||
governor = "schedutil";
|
||||
governor = "powersave";
|
||||
|
||||
# minimum cpu frequency (in kHz)
|
||||
# example: for 800 MHz = 800000 kHz --> scaling_min_freq = 800000
|
||||
# Available: 912 MHz, 1284 MHz, 1752 MHz, 2004 MHz, 2256 MHz, 2424 MHz
|
||||
# 702000 948000 1188000 1452000 1704000 1968000 2208000 2400000 2568000 2724000 2868000 3000000 3132000 3264000
|
||||
# see conversion info: https://www.rapidtables.com/convert/frequency/mhz-to-hz.html
|
||||
# to use this feature, uncomment the following line and set the value accordingly
|
||||
# scaling_min_freq = 800000
|
||||
|
||||
# maximum cpu frequency (in kHz)
|
||||
# see conversion info: https://www.rapidtables.com/convert/frequency/mhz-to-hz.html
|
||||
# example: for 1GHz = 1000 MHz = 1000000 kHz -> scaling_max_freq = 1000000
|
||||
# to use this feature, uncomment the following line and set the value accordingly
|
||||
# scaling_max_freq = 1000000
|
||||
scaling_min_freq = 912000;
|
||||
scaling_max_freq = 2004000;
|
||||
|
||||
# turbo boost setting (always, auto, or never)
|
||||
turbo = "auto";
|
||||
@@ -81,7 +77,7 @@
|
||||
gvfs.enable = true;
|
||||
|
||||
keyd = {
|
||||
enable = true;
|
||||
enable = false;
|
||||
keyboards = {
|
||||
default = {
|
||||
ids = [ "*" ];
|
||||
Reference in New Issue
Block a user