Compare commits

...

27 commits

Author SHA1 Message Date
9e29339de8
->.conf 2024-04-23 10:35:21 +00:00
a6d7a7b04c
try new thing 2024-04-23 10:31:35 +00:00
159b4f4826
try user changes 2024-04-21 19:23:18 +00:00
5ad595d525
why can't pulse die gracefully 2024-04-21 18:03:11 +00:00
f170364400
please 2024-04-20 10:14:18 +00:00
38cb13e81e
die pulse 2024-04-20 09:37:16 +00:00
c2012c8ccf
read the file? 2024-04-20 09:31:04 +00:00
846f6fdbc3
try again pipewire 2024-04-20 09:14:45 +00:00
0fe0536073
try wireplumber thingy 2024-04-18 09:29:41 +00:00
c8f468585a
hwa? 2024-04-10 06:03:34 +00:00
d5714a3e84
enable qualcom quirks 2024-04-10 05:52:52 +00:00
eb10c1c3af
jacky 2024-04-07 05:30:28 +00:00
d73fca4bf2
boot 2024-04-07 04:52:03 +00:00
7d4d14795f
add necessary packages 2024-04-07 04:30:43 +00:00
4091d2aeab
finally steam dead? 2024-04-07 03:04:05 +00:00
6404b1e356
bad steam 2024-04-07 02:56:53 +00:00
4469ec41f7
asdf 2024-04-07 01:47:14 +00:00
d31d3beb06
alsjkdf 2024-04-07 01:44:49 +00:00
e64ef40ed3
thyingy 2024-04-07 01:43:19 +00:00
73a035567c
flake update 2024-04-07 01:39:54 +00:00
11fb88b3cc
I hade phone keyboards 2024-04-01 21:49:04 +00:00
f5bff2f354
user changes 2024-04-01 21:47:00 +00:00
615dce3e41
need to import user config 2024-04-01 21:37:49 +00:00
a66a3015cd
enable some config only on desktop systems 2024-04-01 21:32:50 +00:00
ba4ac7f1f4
change this for better bat 2024-04-01 21:11:51 +00:00
ed6489c559
Update framework config 2024-04-01 21:11:10 +00:00
a8b23e0189
scarab init 2024-03-31 08:40:08 +00:00
10 changed files with 222 additions and 70 deletions

View file

@ -1,10 +1,10 @@
preload = ~/.config/wallpapers/wallpaper.png
preload = ~/.config/wallpapers/current_wallpaper.png
wallpaper = eDP-1,~/.config/wallpapers/wallpaper.png
wallpaper = DP-1,~/.config/wallpapers/wallpaper.png
wallpaper = DP-2,~/.config/wallpapers/wallpaper.png
wallpaper = DP-3,~/.config/wallpapers/wallpaper.png
wallpaper = DP-4,~/.config/wallpapers/wallpaper.png
wallpaper = eDP-1,~/.config/wallpapers/current_wallpaper.png
wallpaper = DP-1,~/.config/wallpapers/current_wallpaper.png
wallpaper = DP-2,~/.config/wallpapers/current_wallpaper.png
wallpaper = DP-3,~/.config/wallpapers/current_wallpaper.png
wallpaper = DP-4,~/.config/wallpapers/current_wallpaper.png
splash=false
ipc = off

View file

@ -8,6 +8,9 @@ unsetopt PROMPT_SP
bindkey -v
# End of lines configured by zsh-newuser-install
# Temporary Rebuild shortcut
alias re-scarab="sudo nixos-rebuild --flake '/etc/nixos#scarab'"
export XDG_CONFIG_HOME="$HOME/.config"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_DATA_HOME="$HOME/.local/share"

View file

@ -38,11 +38,11 @@
]
},
"locked": {
"lastModified": 1710349883,
"narHash": "sha256-bjbdS2mC76xNJwt1d/uZa+JdHR8CCyYbF4Ey/NgOJus=",
"lastModified": 1712390667,
"narHash": "sha256-ebq+fJZfobqpsAdGDGpxNWSySbQejRwW9cdiil6krCo=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "2f0db7d418e781354d8a3c50e611e3b1cd413087",
"rev": "b787726a8413e11b074cde42704b4af32d95545c",
"type": "github"
},
"original": {
@ -55,11 +55,11 @@
"mobile-nixos": {
"flake": false,
"locked": {
"lastModified": 1710655727,
"narHash": "sha256-TOJraNC9vW2gP/ov1RBD+J61pUEJm4q7481Iu6G4ieo=",
"lastModified": 1711757427,
"narHash": "sha256-PqHK0J9YCRKlxpJp+UG+/xpwfIQRPVUPspvbbP3FB2M=",
"owner": "nixos",
"repo": "mobile-nixos",
"rev": "8c59592e8d44c1b30be3fa4e6df7938fa9672be3",
"rev": "f7087f8fdbd1309af315ef8c92345320aadc5edf",
"type": "github"
},
"original": {
@ -68,13 +68,29 @@
"type": "github"
}
},
"nixos-hardware": {
"locked": {
"lastModified": 1712324865,
"narHash": "sha256-+BatEWd4HlMeK7Ora+gYIkarjxFVCg9oKrIeybHIIX4=",
"owner": "Nixos",
"repo": "nixos-hardware",
"rev": "f3b959627bca46a9f7052b8fbc464b8323e68c2c",
"type": "github"
},
"original": {
"owner": "Nixos",
"ref": "master",
"repo": "nixos-hardware",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1710272261,
"narHash": "sha256-g0bDwXFmTE7uGDOs9HcJsfLFhH7fOsASbAuOzDC+fhQ=",
"lastModified": 1712163089,
"narHash": "sha256-Um+8kTIrC19vD4/lUCN9/cU9kcOsD1O1m+axJqQPyMM=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "0ad13a6833440b8e238947e47bea7f11071dc2b2",
"rev": "fd281bd6b7d3e32ddfa399853946f782553163b5",
"type": "github"
},
"original": {
@ -123,6 +139,7 @@
"inputs": {
"home-manager": "home-manager",
"mobile-nixos": "mobile-nixos",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs",
"osu-nixos": "osu-nixos"
}

View file

@ -4,6 +4,7 @@
outputs = inputs@{
nixpkgs,
nixos-hardware,
home-manager,
osu-nixos,
...
@ -28,10 +29,23 @@
}
];
};
scarab = nixpkgs.lib.nixosSystem {
system = "aarch64-linux";
modules = [
{ _module.args = { inherit inputs; }; }
(import "${inputs.mobile-nixos}/lib/configuration.nix" {
device = "oneplus-enchilada";
})
./packages/default.nix
./hosts/scarab/default.nix
./users/stitchynyan/default.nix
];
};
lappy = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [
nixos-hardware.nixosModules.framework-12th-gen-intel
./packages/default.nix
./hosts/lappy/default.nix
@ -68,17 +82,16 @@
};
inputs = {
mobile-nixos = {
url = "github:nixos/mobile-nixos";
flake = false;
};
nixpkgs = {
url = "github:NixOS/nixpkgs/nixos-unstable";
};
home-manager = {
url = "github:nix-community/home-manager/master";
inputs.nixpkgs.follows = "nixpkgs";
};
mobile-nixos = {
url = "github:nixos/mobile-nixos";
flake = false;
};
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
nixos-hardware.url = "github:Nixos/nixos-hardware/master";
osu-nixos.url = "github:Asqiir/osu-nixos";
};
}

View file

@ -15,7 +15,7 @@ in
};
boot = {
kernelPackages = lib.mkDefault pkgs.linuxPackages_zen;
#kernelPackages = lib.mkDefault pkgs.linuxPackages_zen;
loader = {
efi.canTouchEfiVariables = lib.mkDefault true;
systemd-boot.enable = lib.mkDefault true;
@ -24,7 +24,22 @@ in
security.sudo.wheelNeedsPassword = false;
security.rtkit.enable = true;
services.xserver.displayManager.lightdm.enable = false;
services = {
resolved = {
enable = true;
dnsovertls = "opportunistic";
fallbackDns = [
"2620:fe::10#dns10.quad9.net"
"2620:fe::fe:10#dns10.quad9.net"
"9.9.9.10#dns10.quad9.net"
"149.112.112.10#dns10.quad9.net"
];
extraConfig = ''
DNS=2620:fe::10#dns10.quad9.net 2620:fe::fe:10#dns10.quad9.net 9.9.9.10#dns10.quad9.net 149.112.112.10#dns10.quad9.net
'';
};
xserver.displayManager.lightdm.enable = false;
};
# Wireguard stuff, to-do make better
networking.firewall = {

View file

@ -12,77 +12,76 @@
artPkgs.enable = true;
};
system.nixos.tags = [ "Nya_Beginnings" ];
services.logind.powerKey = "ignore";
services.logind.powerKeyLongPress = "poweroff";
services.resolved = {
enable = true;
dnsovertls = "opportunistic";
fallbackDns = [
"2620:fe::10#dns10.quad9.net"
"2620:fe::fe:10#dns10.quad9.net"
"9.9.9.10#dns10.quad9.net"
"149.112.112.10#dns10.quad9.net"
];
extraConfig = ''
DNS=2620:fe::10#dns10.quad9.net 2620:fe::fe:10#dns10.quad9.net 9.9.9.10#dns10.quad9.net 149.112.112.10#dns10.quad9.net
'';
};
networking = {
hostName = "lappy";
networkmanager.enable = true;
};
time.timeZone = "America/Lost_Angeles";
services.syncthing = {
enable = true;
user = "stitchynyan";
openDefaultPorts = true;
databaseDir = "/home/stitchynyan/.local/share/syncthing";
dataDir = "/home/stitchynyan";
};
boot.kernelParams = [
#"intel_pstate=no_hwp"
"kernel.yama.ptrace_scope=0"
#"mem_sleep_default=deep"
"acpi_osi=\"!Windows 2020\""
"module_blacklist=hid_sensor_hub"
#"i915.enable_guc=7"
"intel_iommu=on"
"iommu=pt"
"nvme.noacpi=1"
#"i915.enable_guc=7"
"kernel.yama.ptrace_scope=0"
];
virtualisation.libvirtd.enable = true;
hardware.bluetooth.enable = true;
hardware.bluetooth.settings.General.Experimental = true;
hardware.opengl = {
enable = true;
driSupport = true;
driSupport32Bit = true;
extraPackages = with pkgs; [
intel-compute-runtime
intel-media-driver
];
extraPackages = lib.attrVals [
"intel-compute-runtime"
"intel-media-driver"
] pkgs;
};
systemd.extraConfig =
"AllowedCPUs=8-15"
;
systemd.extraConfig = "AllowedCPUs=8-15";
services.tlp = {
enable = true;
settings = {
TLP_DEFAULT_MODE = "BAT";
TLP_PERSISTENT_DEFAULT = 1;
CPU_SCALING_GOVERNOR_ON_BAT = "schedutil";
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
CPU_HWP_DYN_BOOST_ON_BAT = false;
CPU_SCALING_GOVERNOR_ON_BAT = "schedutil";
CPU_MIN_PERF_ON_AC = 0;
CPU_MAX_PERF_ON_AC = 100;
CPU_MIN_PERF_ON_BAT = 0;
CPU_MAX_PERF_ON_BAT = 50;
#Optional helps save long term battery health
START_CHARGE_THRESH_BAT0 = 40; # 40 and bellow it starts to charge
STOP_CHARGE_THRESH_BAT0 = 90; # 80 and above it stops charging
INTEL_GPU_MAX_FREQ_ON_BAT = 800;
INTEL_GPU_BOOST_FREQ_ON_BAT = 1000;
NMI_WATCHDOG = false;
PCIE_ASPM_ON_AC = "default";
PCIE_ASPM_ON_BAT = "powersupersave";
PLATFORM_PROFILE_ON_BAT = "low-power";
RUNTIME_PM_ON_BAT = true;
WOL_DISABLE = true;
SCHED_POWERSAVE_ON_BAT = true;
USB_AUTOSUSPEND = true;
TLP_DEFAULT_MODE = "BAT";
TLP_PERSISTENT_DEFAULT = 1;
#Optional helps save long term battery health
START_CHARGE_THRESH_BAT0 = 40; # 40 and bellow it starts to charge
STOP_CHARGE_THRESH_BAT0 = 90; # 80 and above it stops charging
};
};

101
hosts/scarab/default.nix Normal file
View file

@ -0,0 +1,101 @@
{ config, inputs, lib, pkgs, ... }:
let
in
{
imports = [
../default.nix
#"${inputs.mobile-nixos}/modules/quirks/qualcomm/sdm845-modem.nix"
#"${inputs.mobile-nixos}/modules/quirks/audio.nix"
];
stitchyconf.form = "handheld";
mobile = {
beautification = {
silentBoot = lib.mkDefault true;
splash = lib.mkDefault true;
};
boot.stage-1 = {
kernel.useStrictKernelConfig = true;
networking.enable = true;
};
quirks = {
audio.alsa-ucm-meld = true;
qualcomm.sdm845-modem.enable = true;
};
};
boot.loader = {
efi.canTouchEfiVariables = false;
systemd-boot.enable = false;
};
#services.openssh.enable = true;
services.xserver.desktopManager.phosh = {
enable = true;
user = "stitchynyan";
group = "users";
};
#services.xserver.desktopManager.plasma5 = {
# enable = true;
# mobile.enable = true;
#};
programs.firefox.enable = true;
programs.calls.enable = true;
hardware = {
bluetooth.enable = true;
pulseaudio.enable = lib.mkForce false;
sensor.iio.enable = true;
};
networking.networkmanager = {
enable = true;
unmanaged = [ "rndis0" "usb0" ];
};
/*services.pipewire.wireplumber.configPackages = [
(pkgs.writeTextDir "share/wireplumber/quailcum.lua.d/51-qcom-sdm845.lua" ''
${builtins.readFile (pkgs.fetchurl {
url = "https://gitlab.com/postmarketOS/pmaports/-/raw/0aa9524204e9c9c002c860b87c972bc2ebf025f3/device/community/soc-qcom-sdm845/51-qcom-sdm845.lua";
hash = "sha256-56oNJJyuZZe1Iig1xskDuyazw3PbRZtmU/YRFUTqjwk=";
})}
'')
];*/
services.pipewire.wireplumber.configPackages = [
(pkgs.writeTextDir "share/wireplumber/wireplumber.conf.d/51-qcom-sdm845.conf" ''
monitor.alsa.rules = [
{
matches = [
{
node.name = "~alsa_output.*"
}
]
actions = {
update-props = {
audio.format = "S16LE"
audio.rate = 48000
api.alsa.period-size = 4096
api.alsa.period-num = 6
api.alsa.headroom = 512
}
}
}
]
'')
];
services.openssh = {
enable = true;
settings.PasswordAuthentication = true;
};
nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [
"oneplus-sdm845-firmware"
"oneplus-sdm845-firmware-xz"
];
system.stateVersion = "23.11";
}

View file

@ -11,6 +11,8 @@ let
] pkgs;
handheldPkgs = lib.attrVals [
"chatty"
"fluffychat"
"gnome-console"
"gnome-text-editor"
"megapixels"
] pkgs;

View file

@ -6,5 +6,6 @@
mutableUsers = false;
users.root.initialHashedPassword = "!";
};
hardware.pulseaudio.enable = false;
};
}

View file

@ -15,29 +15,30 @@
programs = {
firefox.enable = true;
hyprland.enable = true;
openvpn3.enable = true;
hyprland.enable = config.stitchyconf.form == "pc";
openvpn3.enable = config.stitchyconf.form == "pc";
steam = {
enable = true;
enable = config.stitchyconf.form == "pc";
remotePlay.openFirewall = true;
};
};
services = {
avahi = {
enable = true;
enable = false;
nssmdns4 = true;
openFirewall = true;
};
blueman.enable = true;
gnome.gnome-keyring.enable = true;
gnome.gnome-keyring.enable = lib.mkIf( config.stitchyconf.form == "pc") true;
pipewire = {
enable = true;
pulse.enable = true;
enable = lib.mkForce true;
alsa.enable = true;
jack.enable = true;
pulse.enable = true;
};
printing.enable = true;
usbmuxd.enable = true;
printing.enable = false;
usbmuxd.enable = false;
xserver.enable = true;
};