Compare commits

...

9 commits

Author SHA1 Message Date
Emmet f0399b12e3 Updated system 2024-01-01 21:55:34 -06:00
Emmet e738c2475b Hardware + filesystem optimzations (I think..) 2024-01-01 21:55:19 -06:00
Emmet 4eb54c3fe6 Emacs config optimizations 2024-01-01 21:54:01 -06:00
Emmet 5d4f2d6536 This is probably unnecessary in repo 2023-12-30 11:07:40 -06:00
Emmet 467b45963a Various fixes for gaming 2023-12-30 11:05:40 -06:00
Emmet 2eea633dc4 Fix for ensuring time sync 2023-12-24 07:42:21 -06:00
Emmet 526639580f Added network time sync to other profiles 2023-12-24 07:38:23 -06:00
Emmet 8df1df80d1 Some random minor fixes 2023-12-24 07:37:12 -06:00
Emmet 073782130e Tried nix-flatpak but couldn't get hmModule to work 2023-12-21 21:09:44 -06:00
18 changed files with 129 additions and 48 deletions

View file

@ -133,11 +133,11 @@
"blocklist-hosts": {
"flake": false,
"locked": {
"lastModified": 1702838035,
"narHash": "sha256-hTFIG1a/PNgDo5U57VmXDJvR3VWd8TKVinnLfJRlQGo=",
"lastModified": 1703555947,
"narHash": "sha256-3HUeHdEFtZV/I7mRKhpYJ183JbGohQxhgP725vp4PHA=",
"owner": "StevenBlack",
"repo": "hosts",
"rev": "885087bf64df37b10e936e88f0463dd5d6f8d7fa",
"rev": "db884bcfcd86dbe02caecc32c9637302a0e81d08",
"type": "github"
},
"original": {
@ -182,11 +182,11 @@
"eaf": {
"flake": false,
"locked": {
"lastModified": 1702340603,
"narHash": "sha256-b0JOLFatGNpc9zV6gjH6QbMopXX1sAAX+BryySvgYEI=",
"lastModified": 1703893436,
"narHash": "sha256-0UGeo4I4JB95A8W870x4IS6Syh6roMomjTTNQNGbS3E=",
"owner": "emacs-eaf",
"repo": "emacs-application-framework",
"rev": "6932f017932d26363387d18d4fdbeae66aff9459",
"rev": "d55fef029d9a8fa529d2290f2da178dc8ff3d6f7",
"type": "github"
},
"original": {
@ -432,11 +432,11 @@
]
},
"locked": {
"lastModified": 1703108445,
"narHash": "sha256-16U/3eCdekfDUITXDlpGY4iRWvEWIu/U93rP+igvx88=",
"lastModified": 1703838268,
"narHash": "sha256-SRg5nXcdPnrsQR2MTAp7en0NyJnQ2wB1ivmsgEbvN+o=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "0360475ee0fc870bc450874da5b5d7b2a85a091b",
"rev": "2aff324cf65f5f98f89d878c056b779466b17db8",
"type": "github"
},
"original": {
@ -470,11 +470,11 @@
"hyprland-plugins": {
"flake": false,
"locked": {
"lastModified": 1702823915,
"narHash": "sha256-ZHnEiOmV/d+fGslT/rLqPTf8e6i5nLxgNzGjUv7b+IA=",
"lastModified": 1703896182,
"narHash": "sha256-zB/5n6Z/6NqOr6uwwxR71jeNT7u3temhhPCUNzOLl3g=",
"owner": "hyprwm",
"repo": "hyprland-plugins",
"rev": "28c119162091c54dbc81d31ee9db408b3b392fcd",
"rev": "64329fc44f7322badea5ee64fc6d8e24c2b79054",
"type": "github"
},
"original": {
@ -560,11 +560,11 @@
},
"nixpkgs_2": {
"locked": {
"lastModified": 1703013332,
"narHash": "sha256-+tFNwMvlXLbJZXiMHqYq77z/RfmpfpiI3yjL6o/Zo9M=",
"lastModified": 1703637592,
"narHash": "sha256-8MXjxU0RfFfzl57Zy3OfXCITS0qWDNLzlBAdwxGZwfY=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "54aac082a4d9bb5bbc5c4e899603abfb76a3f6d6",
"rev": "cfc3698c31b1fb9cdcf10f36c9643460264d0ca8",
"type": "github"
},
"original": {
@ -672,11 +672,11 @@
"org-nursery": {
"flake": false,
"locked": {
"lastModified": 1691754145,
"narHash": "sha256-NlZ0PVR9v7wVsfdquD3/5WRTTuWwJvKMiLpOqmfo5Js=",
"lastModified": 1703802001,
"narHash": "sha256-WreExyEdR1JH3E0V8oDPZZeqOWdT+4EqwgJebj8zIyc=",
"owner": "chrisbarrett",
"repo": "nursery",
"rev": "0a6634df274c84291a35f92a2cc01ea38b922b07",
"rev": "5cf0a462cd3cfc1410fe11710d947f4ff042cc5e",
"type": "github"
},
"original": {
@ -688,11 +688,11 @@
"org-side-tree": {
"flake": false,
"locked": {
"lastModified": 1703090200,
"narHash": "sha256-XrYlkw8GHvkIaOhcnJWJ5EGojz/ek2UPlwLzKvVyvpo=",
"lastModified": 1703862557,
"narHash": "sha256-VaNqyx9c9dpPvwVwZvd7KbNcVTn4wuZugkdaYCY+s5g=",
"owner": "localauthor",
"repo": "org-side-tree",
"rev": "df915aaf1337fbff5801fad719019ac68c7ff56e",
"rev": "fb7115acbe1f4ba61df28426520889d53275391f",
"type": "github"
},
"original": {
@ -837,11 +837,11 @@
"nixpkgs": "nixpkgs_3"
},
"locked": {
"lastModified": 1703037971,
"narHash": "sha256-HzfW5MLt+I0DlfPM9sL+Vd1XrywoWiW0LSAez3wp23E=",
"lastModified": 1703902408,
"narHash": "sha256-qXdWvu+tlgNjeoz8yQMRKSom6QyRROfgpmeOhwbujqw=",
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "16ab5af8f23b63f34dd7a48a68ab3b50dc3dd2b6",
"rev": "319f57cd2c34348c55970a4bf2b35afe82088681",
"type": "github"
},
"original": {
@ -881,11 +881,11 @@
"nixpkgs": "nixpkgs_4"
},
"locked": {
"lastModified": 1703004037,
"narHash": "sha256-ceYPl/ML0kQBCUaOw0gG2TxHHEl4k9xivFpsdlKidIQ=",
"lastModified": 1703880383,
"narHash": "sha256-YAIbWRAKOCaWDQ4A29xXr79VTuAk9lPJSPYhMBk/VjU=",
"owner": "danth",
"repo": "stylix",
"rev": "d14ac4912a9ab02f8b49b761e9e4b9ae836171af",
"rev": "5a7f3f15ccc2a272e5873bb44fe378ab5d99e0ff",
"type": "github"
},
"original": {

View file

@ -36,8 +36,10 @@
nixpkgs-patched = (import nixpkgs { inherit system; }).applyPatches {
name = "nixpkgs-patched";
src = nixpkgs;
patches = [ ./patches/emacs-no-version-check.patch
./patches/nixos-nixpkgs-268027.patch ];
patches = [
./patches/emacs-no-version-check.patch
./patches/nixos-nixpkgs-268027.patch
];
};
# configure pkgs
@ -55,7 +57,9 @@
homeConfigurations = {
user = home-manager.lib.homeManagerConfiguration {
inherit pkgs;
modules = [ (./. + "/profiles"+("/"+profile)+"/home.nix") ]; # load home.nix from selected PROFILE
modules = [ (./. + "/profiles"+("/"+profile)+"/home.nix") # load home.nix from selected PROFILE
# inputs.nix-flatpak.homeManagerModules.nix-flatpak # Declarative flatpaks
];
extraSpecialArgs = {
# pass config variables from above
inherit username;
@ -75,6 +79,7 @@
inherit term;
inherit spawnEditor;
inherit (inputs) nix-doom-emacs;
#inherit (inputs) nix-flatpak;
inherit (inputs) stylix;
inherit (inputs) eaf;
inherit (inputs) eaf-browser;
@ -116,6 +121,7 @@
nix-doom-emacs.url = "github:librephoenix/nix-doom-emacs?ref=pgtk-patch";
stylix.url = "github:danth/stylix";
rust-overlay.url = "github:oxalica/rust-overlay";
#nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=v0.2.0";
eaf = {
url = "github:emacs-eaf/emacs-application-framework";
flake = false;

View file

@ -3,6 +3,7 @@
{
imports =
[ ../../system/hardware-configuration.nix
../../system/hardware/time.nix # Network time sync
../../system/security/doas.nix
../../system/security/gpg.nix
../../system/security/sshd.nix

View file

@ -9,6 +9,7 @@
../../system/hardware/systemd.nix # systemd config
../../system/hardware/kernel.nix # Kernel config
../../system/hardware/power.nix # Power management
../../system/hardware/time.nix # Network time sync
../../system/hardware/opengl.nix
../../system/hardware/printing.nix
../../system/hardware/bluetooth.nix

View file

@ -13,6 +13,7 @@ in
[ nixos-wsl.nixosModules.wsl
../../system/hardware/kernel.nix # Kernel config
../../system/hardware/systemd.nix # systemd config
../../system/hardware/time.nix # Network time sync
../../system/hardware/opengl.nix
../../system/hardware/printing.nix
../../system/hardware/bluetooth.nix

View file

@ -1,7 +1,7 @@
{ config, lib, pkgs, ... }:
{
environment.systemPackages = with pkgs; [ virt-manager virtualbox ];
environment.systemPackages = with pkgs; [ virt-manager virtualbox distrobox ];
virtualisation.libvirtd = {
allowedBridges = [
"nm-bridge"

View file

@ -13,10 +13,15 @@
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
services.btrfs.autoScrub = {
enable = true;
interval = "weekly";
};
fileSystems."/" =
{ device = "/dev/disk/by-uuid/637d8261-0650-4ece-a35b-59d97baf64a7";
fsType = "btrfs";
options = [ "noatime,compress=lzo,space_cache=v2,subvol=@" ];
options = [ "noatime,compress=zstd:2,space_cache=v2,subvol=@" ];
};
boot.initrd.luks.devices."luks-385106b5-71f7-460e-9a2b-2416f3b54cb6".device = "/dev/disk/by-uuid/385106b5-71f7-460e-9a2b-2416f3b54cb6";

View file

@ -2,6 +2,7 @@
{
boot.kernelPackages = pkgs.linuxPackages_zen;
boot.consoleLogLevel = 0;
boot.extraModulePackages = with config.boot.kernelPackages; [
zenpower
];

View file

@ -1,7 +1,7 @@
{ config, pkgs, ... }:
{
services.journald.extraConfig = "SystemMaxUse=250M\nSystemMaxFiles=10";
services.journald.rateLimitBurst = 800;
services.journald.rateLimitInterval = "5s";
services.journald.extraConfig = "SystemMaxUse=50M\nSystemMaxFiles=5";
services.journald.rateLimitBurst = 500;
services.journald.rateLimitInterval = "30s";
}

5
system/hardware/time.nix Normal file
View file

@ -0,0 +1,5 @@
{ config, lib, pkgs, ... }:
{
services.timesyncd.enable = true;
}

View file

@ -903,7 +903,6 @@ tasks."
"V" 'kill-org-roam-ui)
;;;------ Org agenda configuration ------;;;
;; Set span for agenda to be just daily
(setq org-agenda-span 1
org-agenda-start-day "+0d"
@ -922,7 +921,6 @@ tasks."
'(org-super-agenda-header :inherit custom-button :weight bold :height 1.05)
)
;; Toggle completed entries function
(defun org-agenda-toggle-completed ()
(interactive)

View file

@ -1061,7 +1061,6 @@ On Wayland, EAF doesn't work.
*** Standard Org Agenda Configuration
#+BEGIN_SRC emacs-lisp :tangle config.el
;;;------ Org agenda configuration ------;;;
;; Set span for agenda to be just daily
(setq org-agenda-span 1
org-agenda-start-day "+0d"
@ -1080,7 +1079,6 @@ On Wayland, EAF doesn't work.
'(org-super-agenda-header :inherit custom-button :weight bold :height 1.05)
)
;; Toggle completed entries function
(defun org-agenda-toggle-completed ()
(interactive)
@ -1118,6 +1116,9 @@ On Wayland, EAF doesn't work.
("Personal.p" ,(list (all-the-icons-material "person" :height 0.9)) nil nil :ascent center)
))
#+END_SRC
*** Org Agenda Convenience Functions
#+BEGIN_SRC emacs-lisp :tangle config.el
(defun org-categorize-by-roam-db-on-save ()
(interactive)
(when (string= (message "%s" major-mode) "org-mode")
@ -1166,9 +1167,6 @@ On Wayland, EAF doesn't work.
(revert-buffer nil 'noconfirm)))))
(org-agenda-files)))
#+END_SRC
*** Org Agenda Convenience Functions
#+BEGIN_SRC emacs-lisp :tangle config.el
;; Function to list all my available org agenda files and switch to them
(defun list-and-switch-to-agenda-file ()
"Lists all available agenda files and switches to desired one"
@ -1645,6 +1643,7 @@ EAF doesn't work on Wayland :(
(map! :leader
:desc "Projectile grep"
"/" #'projectile-grep)
#+END_SRC
** sudo-edit
#+BEGIN_SRC emacs-lisp :tangle config.el

View file

@ -5,4 +5,8 @@
home.sessionVariables = {
XDG_DATA_DIRS = "$XDG_DATA_DIRS:/usr/share:/var/lib/flatpak/exports/share:$HOME/.local/share/flatpak/exports/share"; # lets flatpak work
};
#services.flatpak.enable = true;
#services.flatpak.packages = [ { appId = "com.kde.kdenlive"; origin = "flathub"; } ];
#services.flatpak.update.onActivation = true;
}

View file

@ -4,7 +4,18 @@ let
(pkgs.retroarch.override {
cores = with pkgs.libretro; [
vba-m
desmume
(desmume.overrideAttrs (oldAttrs: {
preConfigure = ''
sed -i 's/0009BF123456/0022AA067857/g' desmume/src/firmware.cpp;
sed -i 's/outConfig.MACAddress\[0\] = 0x00/outConfig.MACAddress[0] = 0x00/g' desmume/src/firmware.cpp;
sed -i 's/outConfig.MACAddress\[1\] = 0x09/outConfig.MACAddress[1] = 0x22/g' desmume/src/firmware.cpp;
sed -i 's/outConfig.MACAddress\[2\] = 0xBF/outConfig.MACAddress[2] = 0xAA/g' desmume/src/firmware.cpp;
sed -i 's/outConfig.MACAddress\[3\] = 0x12/outConfig.MACAddress[3] = 0x06/g' desmume/src/firmware.cpp;
sed -i 's/outConfig.MACAddress\[4\] = 0x34/outConfig.MACAddress[4] = 0x78/g' desmume/src/firmware.cpp;
sed -i 's/outConfig.MACAddress\[5\] = 0x56/outConfig.MACAddress[5] = 0x57/g' desmume/src/firmware.cpp;
sed -i 's/0x00, 0x09, 0xBF, 0x12, 0x34, 0x56/0x00, 0x22, 0xAA, 0x06, 0x78, 0x57/g' desmume/src/wifi.cpp;
'';
}))
dolphin
citra
genesis-plus-gx
@ -20,6 +31,16 @@ in
qjoypad
superTux
superTuxKart
# I installed these in distrobox
# and exported using distrobox-export
(pkgs.makeDesktopItem {
name = "pokefinder";
desktopName = "PokeFinder";
exec = "/home/emmet/.local/bin/pokefinder";
terminal = false;
type = "Application";
})
];
nixpkgs.config = {
@ -37,4 +58,9 @@ in
};
# To get steam to import into gamehub, first install it as a flatpak, then
# Set steam directory to ~/.var/app/com.valvesoftware.Steam/.steam
#services.flatpak.packages = [
# "com.discordapp.Discord"
# "com.jaquadro.NBTExplorer"
#];
}

32
user/pkgs/pokefinder.nix Normal file
View file

@ -0,0 +1,32 @@
# THIS DOESN'T WORK YET!!!
# I'M NOT SMART ENOUGH TO FIGURE THIS OUT XD
{ lib, stdenv, fetchgit, pkgs, ... }:
let name = "pokefinder";
version = "4.1.2";
in
stdenv.mkDerivation {
inherit name version;
src = fetchgit {
url = "https://github.com/Admiral-Fish/${name}";
fetchSubmodules = true;
rev = "v${version}";
sha256 = "sha256-ps8F6IcbCNybrZ02tbLNyB3YEvKlcYgCpv5Em7Riv+Q=";
};
buildInputs = with pkgs; [ qt6.full qt6.qttools ];
nativeBuildInputs = with pkgs; [ python3 pkgs.cmake qt6.wrapQtAppsHook ];
cmakeFlags = [
"-DCMAKE_BUILD_TYPE=RELEASE"
"-DCMAKE_PREFIX_PATH=${pkgs.qt6.full}"
];
meta = {
homepage = "https://github.com/Admiral-Fish/PokeFinder";
description = "Cross platform Pokémon RNG tool";
license = lib.licenses.gpl3;
maintainers = [];
};
}

View file

@ -8,13 +8,11 @@ in
src = fetchFromGitLab {
owner = "phoneybadger";
repo = "pokemon-colorscripts";
repo = name;
rev = "0483c85b93362637bdd0632056ff986c07f30868";
sha256 = "sha256-rj0qKYHCu9SyNsj1PZn1g7arjcHuIDGHwubZg/yJt7A=";
};
phases = "installPhase";
installPhase = ''
mkdir -p $out $out/bin $out/opt
cp -rf $src/colorscripts $out/opt
@ -24,7 +22,7 @@ in
'';
meta = {
homepage = "https://gitlab.com/phoneybadger/pokemon-colorscripts";
homepage = "https://github.com/Admiral-Fish/PokeFinder";
description = "CLI utility to print out images of pokemon to terminal";
license = lib.licenses.mit;
maintainers = [];

View file

@ -40,7 +40,7 @@
exec-once = emacs --daemon
#exec-once = swayidle -w timeout 90 '${pkgs.gtklock}/bin/gtklock -d' timeout 210 'suspend-unless-render' resume '${pkgs.hyprland}/bin/hyprctl dispatch dpms on' before-sleep "${pkgs.gtklock}/bin/gtklock -d"
exec-once = swayidle -w timeout 90 '${pkgs.swaylock}/bin/swaylock' timeout 210 'suspend-unless-render' resume '${pkgs.hyprland}/bin/hyprctl dispatch dpms on' before-sleep "${pkgs.swaylock}/bin/swaylock"
exec-once = swayidle -w timeout 90 '${pkgs.swaylock}/bin/swaylock -f' timeout 210 'suspend-unless-render' resume '${pkgs.hyprland}/bin/hyprctl dispatch dpms on' before-sleep "${pkgs.swaylock}/bin/swaylock -f"
exec-once = obs-notification-mute-daemon
exec = ~/.swaybg-stylix
@ -188,6 +188,10 @@
windowrulev2 = workspace special silent,$pavucontrol
windowrulev2 = opacity 0.80,$pavucontrol
windowrulev2 = float,title:^(Kdenlive)$
windowrulev2 = float,class:^(pokefinder)$
windowrulev2 = opacity 0.85,$gearyscratchpad
windowrulev2 = opacity 0.80,title:ORUI
windowrulev2 = opacity 0.80,title:Heimdall