mirror of
				https://github.com/materusPL/Nixerus.git
				synced 2025-11-03 22:20:27 +01:00 
			
		
		
		
	flake: move configurations to other repo
This commit is contained in:
		
							parent
							
								
									9eb2f3ec33
								
							
						
					
					
						commit
						ae765e11da
					
				@ -1,6 +0,0 @@
 | 
				
			|||||||
{ inputs, materusFlake, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  genHomes = import ./genHomes.nix { inherit inputs; inherit materusFlake; };
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{ }
 | 
					 | 
				
			||||||
  // genHomes "materus"
 | 
					 | 
				
			||||||
@ -1,44 +0,0 @@
 | 
				
			|||||||
{ inputs, materusFlake, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  profiles = import ../profile;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  hosts = builtins.attrNames materusFlake.nixosConfigurations;
 | 
					 | 
				
			||||||
  genHomes = username:
 | 
					 | 
				
			||||||
    let
 | 
					 | 
				
			||||||
      #Make host specific user profile "username@host"
 | 
					 | 
				
			||||||
      _list = builtins.map (host: username + "@" + host) hosts;
 | 
					 | 
				
			||||||
      _for = i: (
 | 
					 | 
				
			||||||
        let len = builtins.length hosts; in
 | 
					 | 
				
			||||||
        ([{
 | 
					 | 
				
			||||||
          name = builtins.elemAt _list i;
 | 
					 | 
				
			||||||
          value = let host = builtins.elemAt hosts i; in
 | 
					 | 
				
			||||||
            inputs.home-manager.lib.homeManagerConfiguration {
 | 
					 | 
				
			||||||
              pkgs = materusFlake.nixosConfigurations.${host}.pkgs;
 | 
					 | 
				
			||||||
              extraSpecialArgs = { inherit inputs; inherit materusFlake; };
 | 
					 | 
				
			||||||
              modules = [
 | 
					 | 
				
			||||||
                ./${username}
 | 
					 | 
				
			||||||
                ../host/${host}/extraHome.nix
 | 
					 | 
				
			||||||
                profiles.homeProfile
 | 
					 | 
				
			||||||
                inputs.private.homeModule
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
              ];
 | 
					 | 
				
			||||||
            };
 | 
					 | 
				
			||||||
        }]
 | 
					 | 
				
			||||||
        ++ (if ((i + 1) < len) then _for (i + 1) else [ ]))
 | 
					 | 
				
			||||||
      );
 | 
					 | 
				
			||||||
    in
 | 
					 | 
				
			||||||
    (builtins.listToAttrs (_for 0)) // {
 | 
					 | 
				
			||||||
      #Make generic x86_64-linux user profile "username"
 | 
					 | 
				
			||||||
      ${username} = inputs.home-manager.lib.homeManagerConfiguration {
 | 
					 | 
				
			||||||
        pkgs = import inputs.nixpkgs { system = "x86_64-linux"; config = {allowUnfree = true;}; };
 | 
					 | 
				
			||||||
        extraSpecialArgs = { inherit inputs; inherit materusFlake; };
 | 
					 | 
				
			||||||
        modules = [
 | 
					 | 
				
			||||||
          ./${username}
 | 
					 | 
				
			||||||
          profiles.homeProfile
 | 
					 | 
				
			||||||
          inputs.private.homeModule
 | 
					 | 
				
			||||||
        ];
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
genHomes
 | 
					 | 
				
			||||||
@ -1,10 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  home.username =  "materus";
 | 
					 | 
				
			||||||
  home.packages = [];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  programs.git.signing.key = lib.mkDefault "28D140BCA60B4FD1";
 | 
					 | 
				
			||||||
  programs.git.userEmail = lib.mkDefault "materus@podkos.pl";
 | 
					 | 
				
			||||||
  programs.git.userName = lib.mkDefault "materus";
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,66 +0,0 @@
 | 
				
			|||||||
{ inputs, materusFlake }:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  profiles = import ../profile;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  materusPC = inputs.nixpkgs.lib.nixosSystem rec {
 | 
					 | 
				
			||||||
    specialArgs = { inherit inputs; inherit materusFlake; };
 | 
					 | 
				
			||||||
    system = "x86_64-linux";
 | 
					 | 
				
			||||||
    modules = [
 | 
					 | 
				
			||||||
      ./materusPC
 | 
					 | 
				
			||||||
      inputs.private.systemModule
 | 
					 | 
				
			||||||
      profiles.osProfile
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  flamaster = inputs.nixpkgs.lib.nixosSystem rec {
 | 
					 | 
				
			||||||
    specialArgs = { inherit inputs; inherit materusFlake; };
 | 
					 | 
				
			||||||
    system = "x86_64-linux";
 | 
					 | 
				
			||||||
    modules = [
 | 
					 | 
				
			||||||
      ./flamaster
 | 
					 | 
				
			||||||
      inputs.private.systemModule
 | 
					 | 
				
			||||||
      profiles.osProfile
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      inputs.home-manager.nixosModules.home-manager
 | 
					 | 
				
			||||||
      {
 | 
					 | 
				
			||||||
        home-manager.useGlobalPkgs = true;
 | 
					 | 
				
			||||||
        home-manager.useUserPackages = true;
 | 
					 | 
				
			||||||
        home-manager.users.materus = { config ,... }: {
 | 
					 | 
				
			||||||
          imports = [
 | 
					 | 
				
			||||||
            ../home/materus
 | 
					 | 
				
			||||||
            flamaster/extraHome.nix
 | 
					 | 
				
			||||||
            profiles.homeProfile
 | 
					 | 
				
			||||||
            inputs.private.homeModule
 | 
					 | 
				
			||||||
          ];
 | 
					 | 
				
			||||||
          materus.profile.nixpkgs.enable = false;
 | 
					 | 
				
			||||||
        };
 | 
					 | 
				
			||||||
        home-manager.extraSpecialArgs = { inherit inputs; inherit materusFlake; };
 | 
					 | 
				
			||||||
      }
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  valkyrie = inputs.nixpkgs.lib.nixosSystem rec {
 | 
					 | 
				
			||||||
    specialArgs = { inherit inputs; inherit materusFlake; };
 | 
					 | 
				
			||||||
    system = "x86_64-linux";
 | 
					 | 
				
			||||||
    modules = [
 | 
					 | 
				
			||||||
      ./valkyrie
 | 
					 | 
				
			||||||
      inputs.private.systemModule
 | 
					 | 
				
			||||||
      profiles.osProfile
 | 
					 | 
				
			||||||
      inputs.home-manager.nixosModules.home-manager
 | 
					 | 
				
			||||||
      {
 | 
					 | 
				
			||||||
        home-manager.useGlobalPkgs = true;
 | 
					 | 
				
			||||||
        home-manager.useUserPackages = true;
 | 
					 | 
				
			||||||
        home-manager.users.materus = { config ,... }: {
 | 
					 | 
				
			||||||
          imports = [
 | 
					 | 
				
			||||||
            ../home/materus
 | 
					 | 
				
			||||||
            valkyrie/extraHome.nix
 | 
					 | 
				
			||||||
            profiles.homeProfile
 | 
					 | 
				
			||||||
            inputs.private.homeModule
 | 
					 | 
				
			||||||
          ];
 | 
					 | 
				
			||||||
          materus.profile.nixpkgs.enable = false;
 | 
					 | 
				
			||||||
        };
 | 
					 | 
				
			||||||
        home-manager.extraSpecialArgs = { inherit inputs; inherit materusFlake; };
 | 
					 | 
				
			||||||
      }
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,191 +0,0 @@
 | 
				
			|||||||
# Edit this configuration file to define what should be installed on
 | 
					 | 
				
			||||||
# your system.  Help is available in the configuration.nix(5) man page
 | 
					 | 
				
			||||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
{ config, lib, pkgs, materusFlake, materusPkgs, ... }:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports =
 | 
					 | 
				
			||||||
    [
 | 
					 | 
				
			||||||
      # Include the results of the hardware scan.
 | 
					 | 
				
			||||||
      ./hardware-configuration.nix
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  networking.wireless.iwd.enable = true;
 | 
					 | 
				
			||||||
  services.logind.lidSwitch = "ignore";
 | 
					 | 
				
			||||||
  services.logind.lidSwitchExternalPower = "ignore";
 | 
					 | 
				
			||||||
  programs.steam = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play
 | 
					 | 
				
			||||||
    dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  programs.tmux = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    clock24 = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  programs.java = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    package = pkgs.graalvm-ce;
 | 
					 | 
				
			||||||
    binfmt = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  # Bootloader.
 | 
					 | 
				
			||||||
  boot.loader.grub = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    efiSupport = true;
 | 
					 | 
				
			||||||
    device = "nodev";
 | 
					 | 
				
			||||||
    useOSProber = true;
 | 
					 | 
				
			||||||
    gfxmodeEfi = pkgs.lib.mkDefault "1920x1080";
 | 
					 | 
				
			||||||
    gfxmodeBios = pkgs.lib.mkDefault "1920x1080";
 | 
					 | 
				
			||||||
    #efiInstallAsRemovable = true;	
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  boot.loader.efi.canTouchEfiVariables = true;
 | 
					 | 
				
			||||||
  boot.loader.efi.efiSysMountPoint = "/boot/efi";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  networking.hostName = "flamaster"; # Define your hostname.
 | 
					 | 
				
			||||||
  # networking.wireless.enable = true;  # Enables wireless support via wpa_supplicant.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Configure network proxy if necessary
 | 
					 | 
				
			||||||
  # networking.proxy.default = "http://user:password@proxy:port/";
 | 
					 | 
				
			||||||
  # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable networking
 | 
					 | 
				
			||||||
  networking.networkmanager.enable = true;
 | 
					 | 
				
			||||||
  networking.networkmanager.wifi.backend = "iwd";
 | 
					 | 
				
			||||||
  # Set your time zone.
 | 
					 | 
				
			||||||
  time.timeZone = "Europe/Warsaw";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Select internationalisation properties.
 | 
					 | 
				
			||||||
  i18n.defaultLocale = "pl_PL.utf8";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable the X11 windowing system.
 | 
					 | 
				
			||||||
  services.xserver.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.xserver.videoDrivers = [ "nvidia" ];
 | 
					 | 
				
			||||||
  hardware.opengl.enable = true;
 | 
					 | 
				
			||||||
  hardware.nvidia.prime = {
 | 
					 | 
				
			||||||
    offload.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Bus ID of the Intel GPU. You can find it using lspci, either under 3D or VGA
 | 
					 | 
				
			||||||
    intelBusId = "PCI:0:2:0";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Bus ID of the NVIDIA GPU. You can find it using lspci, either under 3D or VGA
 | 
					 | 
				
			||||||
    nvidiaBusId = "PCI:1:0:0";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable the KDE Plasma Desktop Environment.
 | 
					 | 
				
			||||||
  services.xserver.displayManager.sddm.enable = true;
 | 
					 | 
				
			||||||
  services.xserver.desktopManager.plasma5.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Configure keymap in X11
 | 
					 | 
				
			||||||
  services.xserver = {
 | 
					 | 
				
			||||||
    layout = "pl";
 | 
					 | 
				
			||||||
    xkbVariant = "";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Configure console keymap
 | 
					 | 
				
			||||||
  console.keyMap = "pl2";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable CUPS to print documents.
 | 
					 | 
				
			||||||
  services.printing.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable sound with pipewire.
 | 
					 | 
				
			||||||
  sound.enable = true;
 | 
					 | 
				
			||||||
  hardware.pulseaudio.enable = false;
 | 
					 | 
				
			||||||
  security.rtkit.enable = true;
 | 
					 | 
				
			||||||
  services.pipewire = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    alsa.enable = true;
 | 
					 | 
				
			||||||
    alsa.support32Bit = true;
 | 
					 | 
				
			||||||
    pulse.enable = true;
 | 
					 | 
				
			||||||
    # If you want to use JACK applications, uncomment this
 | 
					 | 
				
			||||||
    jack.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # use the example session manager (no others are packaged yet so this is enabled by default,
 | 
					 | 
				
			||||||
    # no need to redefine it in your config for now)
 | 
					 | 
				
			||||||
    #media-session.enable = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable touchpad support (enabled default in most desktopManager).
 | 
					 | 
				
			||||||
  # services.xserver.libinput.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Define a user account. Don't forget to set a password with ‘passwd’.
 | 
					 | 
				
			||||||
  users.users.materus = {
 | 
					 | 
				
			||||||
    isNormalUser = true;
 | 
					 | 
				
			||||||
    description = "Mateusz Słodkowicz";
 | 
					 | 
				
			||||||
    extraGroups = [ "networkmanager" "wheel" ];
 | 
					 | 
				
			||||||
    openssh.authorizedKeys.keyFiles = [ (materusFlake.path + /extraFiles/keys/ssh/materus.pub) ];
 | 
					 | 
				
			||||||
    packages = with pkgs; [
 | 
					 | 
				
			||||||
      kate
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Allow unfree packages
 | 
					 | 
				
			||||||
  nixpkgs.config.allowUnfree = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # List packages installed in system profile. To search, run:
 | 
					 | 
				
			||||||
  # $ nix search wget
 | 
					 | 
				
			||||||
  environment.systemPackages = with pkgs; [
 | 
					 | 
				
			||||||
    #  vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
 | 
					 | 
				
			||||||
    wget
 | 
					 | 
				
			||||||
    util-linux
 | 
					 | 
				
			||||||
    killall
 | 
					 | 
				
			||||||
    pciutils
 | 
					 | 
				
			||||||
    lshw
 | 
					 | 
				
			||||||
    steamcmd
 | 
					 | 
				
			||||||
    distrobox
 | 
					 | 
				
			||||||
    steamcmd
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    config.materus.profile.packages.firefox
 | 
					 | 
				
			||||||
    config.programs.java.package
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Some programs need SUID wrappers, can be configured further or are
 | 
					 | 
				
			||||||
  # started in user sessions.
 | 
					 | 
				
			||||||
  # programs.mtr.enable = true;
 | 
					 | 
				
			||||||
  # programs.gnupg.agent = {
 | 
					 | 
				
			||||||
  #   enable = true;
 | 
					 | 
				
			||||||
  #   enableSSHSupport = true;
 | 
					 | 
				
			||||||
  # };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # List services that you want to enable:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable the OpenSSH daemon.
 | 
					 | 
				
			||||||
  services.openssh.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Open ports in the firewall.
 | 
					 | 
				
			||||||
  networking.firewall.allowedTCPPorts = [ 22 27015 25565 24454 8123 ];
 | 
					 | 
				
			||||||
  networking.firewall.allowedTCPPortRanges = [{ from = 16262; to = 16272; }];
 | 
					 | 
				
			||||||
  networking.firewall.allowedUDPPorts = [ 22 16261 16262 8766 8767 25565 24454 8123 ];
 | 
					 | 
				
			||||||
  # Or disable the firewall altogether.
 | 
					 | 
				
			||||||
  networking.firewall.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  networking.networkmanager.extraConfig = lib.mkDefault ''
 | 
					 | 
				
			||||||
    [connectivity]
 | 
					 | 
				
			||||||
    uri=http://nmcheck.gnome.org/check_network_status.txt
 | 
					 | 
				
			||||||
  '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # This value determines the NixOS release from which the default
 | 
					 | 
				
			||||||
  # settings for stateful data, like file locations and database versions
 | 
					 | 
				
			||||||
  # on your system were taken. It‘s perfectly fine and recommended to leave
 | 
					 | 
				
			||||||
  # this value at the release version of the first install of this system.
 | 
					 | 
				
			||||||
  # Before changing this value read the documentation for this option
 | 
					 | 
				
			||||||
  # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
 | 
					 | 
				
			||||||
  system.stateVersion = "23.05"; # Did you read the comment?
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  programs.neovim.enable = true;
 | 
					 | 
				
			||||||
  programs.neovim.vimAlias = true;
 | 
					 | 
				
			||||||
  programs.neovim.viAlias = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.flatpak.enable = true;
 | 
					 | 
				
			||||||
  xdg.portal.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  virtualisation.podman.enable = true;
 | 
					 | 
				
			||||||
  virtualisation.podman.dockerCompat = true;
 | 
					 | 
				
			||||||
  virtualisation.podman.enableNvidia = true;
 | 
					 | 
				
			||||||
  virtualisation.podman.dockerSocket.enable = true;
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,12 +0,0 @@
 | 
				
			|||||||
{ config, lib, pkgs, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports =
 | 
					 | 
				
			||||||
    [
 | 
					 | 
				
			||||||
      # Include the results of the hardware scan.
 | 
					 | 
				
			||||||
      ./configuration.nix
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  materus.profile.nix.enable = true;
 | 
					 | 
				
			||||||
  materus.profile.steam.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,21 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, materusPkgs, lib, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  home.stateVersion = "23.05";
 | 
					 | 
				
			||||||
  home.homeDirectory = "/home/materus";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  materus.profile = {
 | 
					 | 
				
			||||||
    fonts.enable = lib.mkDefault true;
 | 
					 | 
				
			||||||
    nixpkgs.enable = lib.mkDefault false;
 | 
					 | 
				
			||||||
    enableDesktop = lib.mkDefault true;
 | 
					 | 
				
			||||||
    enableTerminal = lib.mkDefault true;
 | 
					 | 
				
			||||||
    enableTerminalExtra = lib.mkDefault true;
 | 
					 | 
				
			||||||
    enableNixDevel = lib.mkDefault true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  home.packages = [
 | 
					 | 
				
			||||||
    pkgs.papirus-icon-theme
 | 
					 | 
				
			||||||
    (materusPkgs.polymc.wrap { extraJDKs = [ pkgs.graalvm-ce ]; })
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,54 +0,0 @@
 | 
				
			|||||||
# Do not modify this file!  It was generated by ‘nixos-generate-config’
 | 
					 | 
				
			||||||
# and may be overwritten by future invocations.  Please make changes
 | 
					 | 
				
			||||||
# to /etc/nixos/configuration.nix instead.
 | 
					 | 
				
			||||||
{ config, lib, pkgs, modulesPath, ... }:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports =
 | 
					 | 
				
			||||||
    [
 | 
					 | 
				
			||||||
      (modulesPath + "/installer/scan/not-detected.nix")
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usb_storage" "sd_mod" "rtsx_usb_sdmmc" ];
 | 
					 | 
				
			||||||
  boot.initrd.kernelModules = [ ];
 | 
					 | 
				
			||||||
  boot.kernelModules = [ "kvm-intel" ];
 | 
					 | 
				
			||||||
  boot.extraModulePackages = [ ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/dev/disk/by-label/NixOS_Root";
 | 
					 | 
				
			||||||
      fsType = "ext4";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/boot/efi" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/dev/disk/by-label/NixOS_EFI";
 | 
					 | 
				
			||||||
      fsType = "vfat";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/etc/nixos" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/materus/config/Nixerus";
 | 
					 | 
				
			||||||
      fsType = "none";
 | 
					 | 
				
			||||||
      options = [ "bind" ];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  swapDevices = [{
 | 
					 | 
				
			||||||
    device = "/var/.swapfile";
 | 
					 | 
				
			||||||
    size = 32 * 1024;
 | 
					 | 
				
			||||||
  }];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # 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
 | 
					 | 
				
			||||||
  # still possible to use this option, but it's recommended to use it in conjunction
 | 
					 | 
				
			||||||
  # with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
 | 
					 | 
				
			||||||
  networking.useDHCP = lib.mkDefault true;
 | 
					 | 
				
			||||||
  # networking.interfaces.enp5s0.useDHCP = lib.mkDefault true;
 | 
					 | 
				
			||||||
  # networking.interfaces.wlo1.useDHCP = lib.mkDefault true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
 | 
					 | 
				
			||||||
  powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
 | 
					 | 
				
			||||||
  hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,26 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports =
 | 
					 | 
				
			||||||
    [
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      ./hardware
 | 
					 | 
				
			||||||
      ./vm
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      ./scripts.nix
 | 
					 | 
				
			||||||
      ./tmp.nix
 | 
					 | 
				
			||||||
      ./network.nix
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      ./kde.nix
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
 | 
					 | 
				
			||||||
  system.copySystemConfiguration = false;
 | 
					 | 
				
			||||||
  system.stateVersion = "23.05";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  materus.profile.nix.enable = true;
 | 
					 | 
				
			||||||
  materus.profile.nixpkgs.enable = true;
 | 
					 | 
				
			||||||
  materus.profile.fonts.enable = true;
 | 
					 | 
				
			||||||
  materus.profile.steam.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,38 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, materusPkgs, lib, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  home.stateVersion = "23.05";
 | 
					 | 
				
			||||||
  home.homeDirectory = "/home/materus";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  programs.git.signing.signByDefault = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  materus.profile = {
 | 
					 | 
				
			||||||
    fonts.enable = lib.mkDefault true;
 | 
					 | 
				
			||||||
    nixpkgs.enable = lib.mkDefault false;
 | 
					 | 
				
			||||||
    enableDesktop = lib.mkDefault true;
 | 
					 | 
				
			||||||
    enableTerminal = lib.mkDefault true;
 | 
					 | 
				
			||||||
    enableTerminalExtra = lib.mkDefault true;
 | 
					 | 
				
			||||||
    enableNixDevel = lib.mkDefault true;
 | 
					 | 
				
			||||||
    editor.code.fhs.enable = true;
 | 
					 | 
				
			||||||
    editor.code.fhs.packages = (ps: with ps;[
 | 
					 | 
				
			||||||
      llvmPackages_16.clang
 | 
					 | 
				
			||||||
      llvmPackages_16.llvm
 | 
					 | 
				
			||||||
      llvmPackages_16.bintools
 | 
					 | 
				
			||||||
      llvmPackages_16.lld
 | 
					 | 
				
			||||||
      llvmPackages_16.lldb
 | 
					 | 
				
			||||||
      llvmPackages_16.libllvm
 | 
					 | 
				
			||||||
    ]);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  home.packages = [
 | 
					 | 
				
			||||||
    pkgs.papirus-icon-theme
 | 
					 | 
				
			||||||
    materusPkgs.ffmpeg6-amf-full
 | 
					 | 
				
			||||||
    (materusPkgs.polymc.wrap { extraJDKs = [ pkgs.graalvm-ce ]; extraLibs = [ ]; })
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  programs.obs-studio = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    plugins = with pkgs.obs-studio-plugins; [ wlrobs obs-vaapi obs-vkcapture obs-gstreamer input-overlay obs-multi-rtmp obs-pipewire-audio-capture ];
 | 
					 | 
				
			||||||
    package = materusPkgs.obs-amf;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,45 +0,0 @@
 | 
				
			|||||||
 | 
					 | 
				
			||||||
{ config, pkgs, lib, inputs, materusFlake, materusPkgs, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.xserver.displayManager.gdm.enable = true;
 | 
					 | 
				
			||||||
  services.xserver.displayManager.gdm.wayland = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.xserver.desktopManager.gnome.enable = true;
 | 
					 | 
				
			||||||
  services.xserver.desktopManager.gnome.sessionPath = [ pkgs.gnome.gpaste ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.gnome.gnome-online-accounts.enable = true;
 | 
					 | 
				
			||||||
  services.gnome.gnome-browser-connector.enable = true;
 | 
					 | 
				
			||||||
  services.gnome.core-utilities.enable = true;
 | 
					 | 
				
			||||||
  services.gnome.core-shell.enable = true;
 | 
					 | 
				
			||||||
  services.gnome.core-os-services.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  programs.gnupg.agent.pinentryFlavor = "gnome3";
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  programs.gnome-terminal.enable = true;
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  services.udev.packages = with pkgs; [ gnome.gnome-settings-daemon ];
 | 
					 | 
				
			||||||
  services.dbus.packages = with pkgs; [ gnome2.GConf ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  environment.systemPackages = with pkgs; [
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      gnome3.adwaita-icon-theme
 | 
					 | 
				
			||||||
      gnome3.gnome-tweaks
 | 
					 | 
				
			||||||
      gnome3.gnome-color-manager
 | 
					 | 
				
			||||||
      gnome3.gnome-shell-extensions
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      gnomeExtensions.appindicator
 | 
					 | 
				
			||||||
      gnomeExtensions.desktop-clock
 | 
					 | 
				
			||||||
      gnomeExtensions.gtk4-desktop-icons-ng-ding
 | 
					 | 
				
			||||||
      gnomeExtensions.compiz-windows-effect
 | 
					 | 
				
			||||||
      gnomeExtensions.burn-my-windows
 | 
					 | 
				
			||||||
      gnomeExtensions.user-themes
 | 
					 | 
				
			||||||
      gnomeExtensions.gsconnect
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,55 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, ... }:
 | 
					 | 
				
			||||||
let 
 | 
					 | 
				
			||||||
video = [
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  "video=HDMI-A-3:1920x1080@144"
 | 
					 | 
				
			||||||
  "video=DP-3:1920x1080@240"
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  #"video=DP-1:1920x1080@240"
 | 
					 | 
				
			||||||
  #"video=DP-2:1920x1080@240"
 | 
					 | 
				
			||||||
  #"video=HDMI-A-1:1920x1080@240"
 | 
					 | 
				
			||||||
  #"video=HDMI-A-2:1920x1080@240"
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
];
 | 
					 | 
				
			||||||
in 
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  #Kernel
 | 
					 | 
				
			||||||
  boot.kernelPackages = pkgs.linuxPackages_zen;
 | 
					 | 
				
			||||||
  boot.kernelParams = [ /*"pci-stub.ids=1002:744c"*/ "nox2apic" "nvme_core.default_ps_max_latency_us=0" "nvme_core.io_timeout=255" "nvme_core.max_retries=10" "nvme_core.shutdown_timeout=10" "amd_iommu=on" "iommu=pt"] ++ video;
 | 
					 | 
				
			||||||
  boot.kernelModules = [ "pci-stub" "amdgpu" "i2c_dev" "kvm_amd" "vfio" "vfio_iommu_type1" "vfio-pci" "v4l2loopback" ];
 | 
					 | 
				
			||||||
  boot.extraModprobeConfig = ''
 | 
					 | 
				
			||||||
  options kvm_amd nested=1 avic=1 npt=1
 | 
					 | 
				
			||||||
  options vfio_iommu_type1 allow_unsafe_interrupts=1
 | 
					 | 
				
			||||||
  '';
 | 
					 | 
				
			||||||
  boot.kernel.sysctl = {
 | 
					 | 
				
			||||||
                        "vm.max_map_count" = 1000000;
 | 
					 | 
				
			||||||
                        "vm.swappiness" = 10;
 | 
					 | 
				
			||||||
                       };
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usb_storage" "usbhid" "sd_mod" ];
 | 
					 | 
				
			||||||
  boot.initrd.kernelModules = [ ];
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  boot.extraModulePackages = with config.boot.kernelPackages; [ v4l2loopback ];
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  boot.supportedFilesystems = [ "ntfs" "btrfs" "vfat" "exfat" "ext4"];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  boot.tmp.useTmpfs = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  #bootloader
 | 
					 | 
				
			||||||
  boot.loader.efi.canTouchEfiVariables = true;
 | 
					 | 
				
			||||||
  boot.loader.efi.efiSysMountPoint = "/boot/efi";
 | 
					 | 
				
			||||||
  boot.loader.grub = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    efiSupport = true;
 | 
					 | 
				
			||||||
    device = "nodev";
 | 
					 | 
				
			||||||
    gfxmodeEfi = pkgs.lib.mkDefault "1920x1080@240";
 | 
					 | 
				
			||||||
    gfxmodeBios = pkgs.lib.mkDefault "1920x1080@240";
 | 
					 | 
				
			||||||
    useOSProber = true;
 | 
					 | 
				
			||||||
    memtest86.enable = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,55 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, materusPkgs, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports =
 | 
					 | 
				
			||||||
    [
 | 
					 | 
				
			||||||
      ./filesystem.nix
 | 
					 | 
				
			||||||
      ./boot.nix
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  hardware.firmware = with pkgs; [
 | 
					 | 
				
			||||||
    materusPkgs.amdgpu-pro-libs.firmware.vcn
 | 
					 | 
				
			||||||
    #materusPkgs.amdgpu-pro-libs.firmware
 | 
					 | 
				
			||||||
    linux-firmware
 | 
					 | 
				
			||||||
    alsa-firmware
 | 
					 | 
				
			||||||
    sof-firmware
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
  hardware.cpu.amd.updateMicrocode = lib.mkForce true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  #extra
 | 
					 | 
				
			||||||
  hardware.wooting.enable = true;
 | 
					 | 
				
			||||||
  hardware.bluetooth.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  #Graphics
 | 
					 | 
				
			||||||
  hardware.opengl.enable = true;
 | 
					 | 
				
			||||||
  hardware.opengl.driSupport32Bit = true;
 | 
					 | 
				
			||||||
  hardware.opengl.extraPackages = with pkgs; [
 | 
					 | 
				
			||||||
    vaapiVdpau
 | 
					 | 
				
			||||||
    libvdpau-va-gl
 | 
					 | 
				
			||||||
    amdvlk
 | 
					 | 
				
			||||||
    rocm-opencl-icd
 | 
					 | 
				
			||||||
    rocm-opencl-runtime
 | 
					 | 
				
			||||||
    materusPkgs.amdgpu-pro-libs.vulkan
 | 
					 | 
				
			||||||
    materusPkgs.amdgpu-pro-libs.amf
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
  hardware.opengl.extraPackages32 = with pkgs.pkgsi686Linux; [
 | 
					 | 
				
			||||||
    vaapiVdpau
 | 
					 | 
				
			||||||
    pkgs.driversi686Linux.amdvlk
 | 
					 | 
				
			||||||
    materusPkgs.i686Linux.amdgpu-pro-libs.vulkan
 | 
					 | 
				
			||||||
    libvdpau-va-gl
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
  services.udev.extraRules = ''
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    #GPU bar size
 | 
					 | 
				
			||||||
    ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x1002", ATTR{device}=="0x744c", ATTR{resource0_resize}="15"
 | 
					 | 
				
			||||||
    ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x1002", ATTR{device}=="0x744c", ATTR{resource2_resize}="8"
 | 
					 | 
				
			||||||
  '';
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  #Trim
 | 
					 | 
				
			||||||
  services.fstrim = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    interval = "weekly";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,69 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  zramSwap = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    memoryPercent = 25;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  swapDevices = [
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      label = "NixOS_Swap";
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/etc/nixos" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/materus/config/Nixerus";
 | 
					 | 
				
			||||||
      fsType = "none";
 | 
					 | 
				
			||||||
      options = [ "bind" ];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/materus" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/dev/disk/by-label/NixOS_Root";
 | 
					 | 
				
			||||||
      fsType = "btrfs";
 | 
					 | 
				
			||||||
      options = [ "subvol=@materus" "noatime" "compress=zstd" "ssd" "space_cache=v2" ];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/dev/disk/by-label/NixOS_Root";
 | 
					 | 
				
			||||||
      fsType = "btrfs";
 | 
					 | 
				
			||||||
      options = [ "subvol=@" "noatime" "ssd" "space_cache=v2" "compress=zstd" ];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/nix" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/dev/disk/by-label/NixOS_Root";
 | 
					 | 
				
			||||||
      fsType = "btrfs";
 | 
					 | 
				
			||||||
      options = [ "subvol=@nix" "noatime" "compress=zstd" "ssd" "space_cache=v2" ];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/home" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/dev/disk/by-label/NixOS_Root";
 | 
					 | 
				
			||||||
      fsType = "btrfs";
 | 
					 | 
				
			||||||
      options = [ "subvol=@home" "noatime" "compress=zstd" "ssd" "space_cache=v2" ];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/boot" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/dev/disk/by-label/NixOS_Root";
 | 
					 | 
				
			||||||
      fsType = "btrfs";
 | 
					 | 
				
			||||||
      options = [ "subvol=@boot" "ssd" ];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/boot/efi" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/dev/disk/by-label/NixOS_EFI";
 | 
					 | 
				
			||||||
      fsType = "vfat";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,61 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  westonSddm = pkgs.writeText "weston.ini"
 | 
					 | 
				
			||||||
    ''
 | 
					 | 
				
			||||||
      [core]
 | 
					 | 
				
			||||||
      xwayland=true
 | 
					 | 
				
			||||||
      shell=fullscreen-shell.so
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      [keyboard]
 | 
					 | 
				
			||||||
      keymap_layout=pl
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      [output]
 | 
					 | 
				
			||||||
      name=DP-3
 | 
					 | 
				
			||||||
      mode=1920x1080@240
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      [output]
 | 
					 | 
				
			||||||
      name=DP-2
 | 
					 | 
				
			||||||
      mode=off
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      [output]
 | 
					 | 
				
			||||||
      name=HDMI-A-3
 | 
					 | 
				
			||||||
      mode=off
 | 
					 | 
				
			||||||
    ''
 | 
					 | 
				
			||||||
  ;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  services.xserver.displayManager.defaultSession = "plasmawayland";
 | 
					 | 
				
			||||||
  services.xserver.displayManager.sddm.enable = true;
 | 
					 | 
				
			||||||
  services.xserver.displayManager.sddm.settings = {
 | 
					 | 
				
			||||||
    General = {
 | 
					 | 
				
			||||||
      DisplayServer = "wayland";
 | 
					 | 
				
			||||||
      InputMethod="";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
    Theme = {
 | 
					 | 
				
			||||||
      CursorTheme = "breeze_cursors";
 | 
					 | 
				
			||||||
      CursorSize = "24";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
    Wayland = {
 | 
					 | 
				
			||||||
      CompositorCommand = "${pkgs.weston}/bin/weston  -c ${westonSddm}";
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  services.xserver.desktopManager.plasma5.enable = true;
 | 
					 | 
				
			||||||
  services.xserver.desktopManager.plasma5.phononBackend = "gstreamer";
 | 
					 | 
				
			||||||
  services.xserver.desktopManager.plasma5.useQtScaling = true;
 | 
					 | 
				
			||||||
  services.xserver.desktopManager.plasma5.runUsingSystemd = true;
 | 
					 | 
				
			||||||
  programs.gnupg.agent.pinentryFlavor = "qt";
 | 
					 | 
				
			||||||
  environment.plasma5.excludePackages = with pkgs; [ libsForQt5.kwallet libsForQt5.kwalletmanager libsForQt5.kwallet-pam ];
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  environment.variables = {
 | 
					 | 
				
			||||||
    # Old fix for black cursor on amdgpu, seems to work fine now
 | 
					 | 
				
			||||||
    #KWIN_DRM_NO_AMS = "1";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    #Fix fo amdgpu crashes
 | 
					 | 
				
			||||||
    KWIN_DRM_USE_MODIFIERS="0";
 | 
					 | 
				
			||||||
    KWIN_DRM_NO_DIRECT_SCANOUT="1";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  environment.systemPackages = with pkgs; [
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,18 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  networking.useDHCP = lib.mkDefault true;
 | 
					 | 
				
			||||||
  networking.hostName = "materusPC";
 | 
					 | 
				
			||||||
  networking.wireless.iwd.enable = true;
 | 
					 | 
				
			||||||
  networking.networkmanager.enable = true;
 | 
					 | 
				
			||||||
  networking.networkmanager.wifi.backend = "iwd";
 | 
					 | 
				
			||||||
  networking.firewall.enable = true;
 | 
					 | 
				
			||||||
  networking.firewall.allowedTCPPorts = [ 24800 5900 5357 4656 8080 9943 9944];
 | 
					 | 
				
			||||||
  networking.firewall.allowedUDPPorts = [ 24800 5900 3702 4656 6000 9943 9944];
 | 
					 | 
				
			||||||
  #Fix warning
 | 
					 | 
				
			||||||
  networking.networkmanager.extraConfig = lib.mkDefault ''
 | 
					 | 
				
			||||||
    [connectivity]
 | 
					 | 
				
			||||||
    uri=http://nmcheck.gnome.org/check_network_status.txt
 | 
					 | 
				
			||||||
  '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,59 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
valkyrie-sync = pkgs.writeShellScriptBin "valkyrie-sync" ''
 | 
					 | 
				
			||||||
${pkgs.rsync}/bin/rsync -avzrh --delete --exclude ".git*" --exclude "flake.lock" /materus/config/Nixerus materus@valkyrie:/materus/config/ && \
 | 
					 | 
				
			||||||
  ${pkgs.rsync}/bin/rsync -avzrh --delete --exclude ".git*" /materus/config/valkyrie materus@valkyrie:/materus/config/
 | 
					 | 
				
			||||||
'';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
valkyrie-flakelock = pkgs.writeShellScriptBin "valkyrie-flakelock" ''
 | 
					 | 
				
			||||||
${pkgs.openssh}/bin/ssh materus@valkyrie "nix flake update /materus/config/Nixerus --override-input nixpkgs github:NixOS/nixpkgs/23.05 \
 | 
					 | 
				
			||||||
  --override-input home-manager github:nix-community/home-manager/release-23.05 \
 | 
					 | 
				
			||||||
  --override-input private /materus/config/valkyrie/flake"
 | 
					 | 
				
			||||||
'';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
valkyrie-rebuild-boot = pkgs.writeShellScriptBin "valkyrie-rebuild-boot" ''
 | 
					 | 
				
			||||||
${pkgs.openssh}/bin/ssh -t materus@valkyrie "sudo nixos-rebuild boot --flake /materus/config/Nixerus#valkyrie \
 | 
					 | 
				
			||||||
  --override-input private /materus/config/valkyrie/flake"
 | 
					 | 
				
			||||||
'';
 | 
					 | 
				
			||||||
valkyrie-rebuild-switch = pkgs.writeShellScriptBin "valkyrie-rebuild-switch" ''
 | 
					 | 
				
			||||||
${pkgs.openssh}/bin/ssh -t materus@valkyrie "sudo nixos-rebuild switch --flake /materus/config/Nixerus#valkyrie \
 | 
					 | 
				
			||||||
  --override-input private /materus/config/valkyrie/flake"
 | 
					 | 
				
			||||||
'';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
flamaster-sync = pkgs.writeShellScriptBin "flamaster-sync" ''
 | 
					 | 
				
			||||||
${pkgs.rsync}/bin/rsync -avzrh --delete --exclude ".git*" --exclude "flake.lock" /materus/config/Nixerus materus@flamaster:/materus/config/ && \
 | 
					 | 
				
			||||||
  ${pkgs.rsync}/bin/rsync -avzrh --delete --exclude ".git*" /materus/config/flamaster materus@flamaster:/materus/config/
 | 
					 | 
				
			||||||
'';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
flamaster-flakelock = pkgs.writeShellScriptBin "flamaster-flakelock" ''
 | 
					 | 
				
			||||||
${pkgs.openssh}/bin/ssh materus@flamaster "nix flake update /materus/config/Nixerus --override-input nixpkgs github:NixOS/nixpkgs/23.05 \
 | 
					 | 
				
			||||||
  --override-input home-manager github:nix-community/home-manager/release-23.05 \
 | 
					 | 
				
			||||||
  --override-input private /materus/config/flamaster/flake"
 | 
					 | 
				
			||||||
'';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
flamaster-rebuild-boot = pkgs.writeShellScriptBin "flamaster-rebuild-boot" ''
 | 
					 | 
				
			||||||
${pkgs.openssh}/bin/ssh -t materus@flamaster "sudo nixos-rebuild boot --flake /materus/config/Nixerus#flamaster \
 | 
					 | 
				
			||||||
  --override-input private /materus/config/flamaster/flake"
 | 
					 | 
				
			||||||
'';
 | 
					 | 
				
			||||||
flamaster-rebuild-switch = pkgs.writeShellScriptBin "flamaster-rebuild-switch" ''
 | 
					 | 
				
			||||||
${pkgs.openssh}/bin/ssh -t materus@flamaster "sudo nixos-rebuild switch --flake /materus/config/Nixerus#flamaster \
 | 
					 | 
				
			||||||
  --override-input private /materus/config/flamaster/flake"
 | 
					 | 
				
			||||||
'';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{ 
 | 
					 | 
				
			||||||
  environment.systemPackages = [
 | 
					 | 
				
			||||||
    valkyrie-rebuild-boot
 | 
					 | 
				
			||||||
    valkyrie-rebuild-switch
 | 
					 | 
				
			||||||
    valkyrie-sync
 | 
					 | 
				
			||||||
    valkyrie-flakelock
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    flamaster-rebuild-boot
 | 
					 | 
				
			||||||
    flamaster-rebuild-switch
 | 
					 | 
				
			||||||
    flamaster-sync
 | 
					 | 
				
			||||||
    flamaster-flakelock
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,442 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, materusPkgs, ... }:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  virtualisation.lxc.enable = false;
 | 
					 | 
				
			||||||
  virtualisation.lxc.lxcfs.enable = false;
 | 
					 | 
				
			||||||
  virtualisation.lxd.enable = false;
 | 
					 | 
				
			||||||
  #virtualisation.lxd.recommendedSysctlSettings = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  programs.corectrl.enable = true;
 | 
					 | 
				
			||||||
  programs.corectrl.gpuOverclock.enable = true;
 | 
					 | 
				
			||||||
  programs.corectrl.gpuOverclock.ppfeaturemask = "0xffffffff";
 | 
					 | 
				
			||||||
  programs.gamemode.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.teamviewer.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  systemd.tmpfiles.rules = [
 | 
					 | 
				
			||||||
    "L+    /opt/rocm/hip   -    -    -     -    ${pkgs.hip}"
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.flatpak.enable = true;
 | 
					 | 
				
			||||||
  services.gvfs.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  time.timeZone = "Europe/Warsaw";
 | 
					 | 
				
			||||||
  i18n.defaultLocale = "pl_PL.UTF-8";
 | 
					 | 
				
			||||||
  console = {
 | 
					 | 
				
			||||||
    font = "lat2-16";
 | 
					 | 
				
			||||||
    #     keyMap = "pl";
 | 
					 | 
				
			||||||
    useXkbConfig = true; # use xkbOptions in tty.
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  services.xserver.layout = "pl";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.xserver.enable = true;
 | 
					 | 
				
			||||||
  services.xserver.videoDrivers = [ "amdgpu" ];
 | 
					 | 
				
			||||||
  services.dbus.enable = true;
 | 
					 | 
				
			||||||
  services.dbus.packages = [ pkgs.gcr_4 ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  #services.xserver.displayManager.autoLogin.user = "materus";
 | 
					 | 
				
			||||||
  services.xserver.displayManager.startx.enable = false;
 | 
					 | 
				
			||||||
  /*
 | 
					 | 
				
			||||||
    services.xserver.displayManager.lightdm.enable = true;
 | 
					 | 
				
			||||||
    services.xserver.displayManager.lightdm.greeters.enso.enable = true;
 | 
					 | 
				
			||||||
    services.xserver.displayManager.lightdm.greeters.enso.blur = true;
 | 
					 | 
				
			||||||
  */
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  services.xserver.config = pkgs.lib.mkAfter ''
 | 
					 | 
				
			||||||
    Section "OutputClass"
 | 
					 | 
				
			||||||
      Identifier "amd-options"
 | 
					 | 
				
			||||||
      Option "TearFree" "True"
 | 
					 | 
				
			||||||
      Option "SWCursor" "True"
 | 
					 | 
				
			||||||
      Option "VariableRefresh" "true"
 | 
					 | 
				
			||||||
      Option "AsyncFlipSecondaries" "true"
 | 
					 | 
				
			||||||
      MatchDriver "amdgpu"
 | 
					 | 
				
			||||||
    EndSection
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.printing.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  sound.enable = true;
 | 
					 | 
				
			||||||
  security.rtkit.enable = true;
 | 
					 | 
				
			||||||
  services.pipewire = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    audio.enable = true;
 | 
					 | 
				
			||||||
    alsa.enable = true;
 | 
					 | 
				
			||||||
    alsa.support32Bit = true;
 | 
					 | 
				
			||||||
    pulse.enable = true;
 | 
					 | 
				
			||||||
    systemWide = false;
 | 
					 | 
				
			||||||
    # If you want to use JACK applications, uncomment this
 | 
					 | 
				
			||||||
    jack.enable = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  hardware.pulseaudio.enable = false;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.xserver.libinput.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  virtualisation.waydroid.enable = false;
 | 
					 | 
				
			||||||
  virtualisation.podman = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    #enableNvidia = true;
 | 
					 | 
				
			||||||
    dockerCompat = true;
 | 
					 | 
				
			||||||
    dockerSocket.enable = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  users.users.materus = {
 | 
					 | 
				
			||||||
    isNormalUser = true;
 | 
					 | 
				
			||||||
    extraGroups = [ "audio" "video" "render" "pipewire" "wheel" "networkmanager" "input" "kvm" "libvirt-qemu" "libvirt" "libvirtd" "podman" "lxd" ]; # Enable ‘sudo’ for the user.
 | 
					 | 
				
			||||||
    shell = pkgs.bashInteractive;
 | 
					 | 
				
			||||||
    description = "Mateusz Słodkowicz";
 | 
					 | 
				
			||||||
    #   packages = with pkgs; [
 | 
					 | 
				
			||||||
    #     firefox
 | 
					 | 
				
			||||||
    #     thunderbird
 | 
					 | 
				
			||||||
    #   ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  environment.variables = {
 | 
					 | 
				
			||||||
    DISABLE_LAYER_AMD_SWITCHABLE_GRAPHICS_1 = "1";
 | 
					 | 
				
			||||||
    VK_ICD_FILENAMES = "/run/opengl-driver/share/vulkan/icd.d/radeon_icd.x86_64.json:/run/opengl-driver-32/share/vulkan/icd.d/radeon_icd.i686.json";
 | 
					 | 
				
			||||||
    AMD_VULKAN_ICD = "RADV";
 | 
					 | 
				
			||||||
    RADV_PERFTEST = "gpl,rt,sam";
 | 
					 | 
				
			||||||
    ALSOFT_DRIVERS = "pulse";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  environment.sessionVariables = rec {
 | 
					 | 
				
			||||||
    XDG_CACHE_HOME = "\${HOME}/.cache";
 | 
					 | 
				
			||||||
    XDG_CONFIG_HOME = "\${HOME}/.config";
 | 
					 | 
				
			||||||
    XDG_BIN_HOME = "\${HOME}/.local/bin";
 | 
					 | 
				
			||||||
    XDG_DATA_HOME = "\${HOME}/.local/share";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    SDL_AUDIODRIVER = "pipewire";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    #SSH_ASKPASS_REQUIRE = "prefer";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    MOZ_USE_XINPUT2 = "1";
 | 
					 | 
				
			||||||
    PATH = [
 | 
					 | 
				
			||||||
      "\${XDG_BIN_HOME}"
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  environment.shellInit = ''
 | 
					 | 
				
			||||||
    if ! [ -z "$DISPLAY" ]; then xhost +si:localuser:root &> /dev/null; fi;
 | 
					 | 
				
			||||||
    if ! [ -z "$DISPLAY" ]; then xhost +si:localuser:$USER &> /dev/null; fi;
 | 
					 | 
				
			||||||
  '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  i18n.inputMethod.enabled = "fcitx5";
 | 
					 | 
				
			||||||
  i18n.inputMethod.fcitx5.addons = [ pkgs.fcitx5-configtool pkgs.fcitx5-lua pkgs.fcitx5-mozc pkgs.fcitx5-gtk pkgs.libsForQt5.fcitx5-qt ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Some programs need SUID wrappers, can be configured further or are
 | 
					 | 
				
			||||||
  # started in user sessions.
 | 
					 | 
				
			||||||
  # programs.mtr.enable = true;
 | 
					 | 
				
			||||||
  services.pcscd.enable = true;
 | 
					 | 
				
			||||||
  services.samba-wsdd.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.samba = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    package = pkgs.sambaFull;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  programs.gnupg.agent = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    enableSSHSupport = false;
 | 
					 | 
				
			||||||
    enableBrowserSocket = true;
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  programs.ssh.startAgent = true;
 | 
					 | 
				
			||||||
  services.openssh.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  environment.enableAllTerminfo = true;
 | 
					 | 
				
			||||||
  environment.pathsToLink = [ "/share/zsh" "/share/bash-completion" "/share/fish" ];
 | 
					 | 
				
			||||||
  environment.shells = with pkgs; [ zsh bashInteractive fish ];
 | 
					 | 
				
			||||||
  programs = {
 | 
					 | 
				
			||||||
    fish.enable = true;
 | 
					 | 
				
			||||||
    zsh = {
 | 
					 | 
				
			||||||
      enable = true;
 | 
					 | 
				
			||||||
      interactiveShellInit = ''
 | 
					 | 
				
			||||||
        if [[ ''${__MATERUS_HM_ZSH:-0} == 0 ]]; then
 | 
					 | 
				
			||||||
          source ${pkgs.grml-zsh-config}/etc/zsh/zshrc
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
      '';
 | 
					 | 
				
			||||||
      promptInit = ''
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      '';
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
    java.enable = true;
 | 
					 | 
				
			||||||
    java.package = pkgs.graalvm-ce;
 | 
					 | 
				
			||||||
    java.binfmt = true;
 | 
					 | 
				
			||||||
    command-not-found.enable = false;
 | 
					 | 
				
			||||||
    dconf.enable = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  /*containers.test = {
 | 
					 | 
				
			||||||
    config = { config, pkgs, ... }: { environment.systemPackages = with pkgs; [ wayfire ]; };
 | 
					 | 
				
			||||||
    autoStart = false;
 | 
					 | 
				
			||||||
    };*/
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  environment.systemPackages = with pkgs; [
 | 
					 | 
				
			||||||
    firefox
 | 
					 | 
				
			||||||
    gamescope
 | 
					 | 
				
			||||||
    #(pkgs.lutris.override { extraLibraries = pkgs: with pkgs;  [ pkgs.samba pkgs.jansson pkgs.tdb pkgs.libunwind pkgs.libusb1 pkgs.gnutls pkgs.gtk3 pkgs.pango ]; })
 | 
					 | 
				
			||||||
    materusPkgs.amdgpu-pro-libs.prefixes
 | 
					 | 
				
			||||||
    (pkgs.bottles.override { extraPkgs = pkgs: with pkgs; [ pkgs.libsForQt5.breeze-qt5 pkgs.libsForQt5.breeze-gtk pkgs.nss_latest ]; extraLibraries = pkgs: with pkgs; [ pkgs.samba pkgs.jansson pkgs.tdb pkgs.libunwind pkgs.libusb1 pkgs.gnutls pkgs.gtk3 pkgs.pango ]; })
 | 
					 | 
				
			||||||
    glibc
 | 
					 | 
				
			||||||
    glib
 | 
					 | 
				
			||||||
    gtk3
 | 
					 | 
				
			||||||
    gtk4
 | 
					 | 
				
			||||||
    gsettings-desktop-schemas
 | 
					 | 
				
			||||||
    libsForQt5.dolphin
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    patchelf
 | 
					 | 
				
			||||||
    killall
 | 
					 | 
				
			||||||
    util-linux
 | 
					 | 
				
			||||||
    xorg.xhost
 | 
					 | 
				
			||||||
    nix-top
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    gitFull
 | 
					 | 
				
			||||||
    curl
 | 
					 | 
				
			||||||
    wget
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    config.programs.java.package
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    nss_latest
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    aspell
 | 
					 | 
				
			||||||
    aspellDicts.pl
 | 
					 | 
				
			||||||
    aspellDicts.en
 | 
					 | 
				
			||||||
    aspellDicts.en-computers
 | 
					 | 
				
			||||||
    steamtinkerlaunch
 | 
					 | 
				
			||||||
    distrobox
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    p7zip
 | 
					 | 
				
			||||||
    unrar
 | 
					 | 
				
			||||||
    bzip2
 | 
					 | 
				
			||||||
    rar
 | 
					 | 
				
			||||||
    unzip
 | 
					 | 
				
			||||||
    zstd
 | 
					 | 
				
			||||||
    xz
 | 
					 | 
				
			||||||
    zip
 | 
					 | 
				
			||||||
    gzip
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    tree
 | 
					 | 
				
			||||||
    mc
 | 
					 | 
				
			||||||
    lf
 | 
					 | 
				
			||||||
    htop
 | 
					 | 
				
			||||||
    nmon
 | 
					 | 
				
			||||||
    iftop
 | 
					 | 
				
			||||||
    iptraf-ng
 | 
					 | 
				
			||||||
    mprocs
 | 
					 | 
				
			||||||
    tldr
 | 
					 | 
				
			||||||
    bat
 | 
					 | 
				
			||||||
    config.materus.profile.packages.home-manager
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # pgcli
 | 
					 | 
				
			||||||
    # litecli
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    #zenmonitor
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    nix-du
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    ark
 | 
					 | 
				
			||||||
    kate
 | 
					 | 
				
			||||||
    krusader
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    wineWowPackages.stagingFull
 | 
					 | 
				
			||||||
    winetricks
 | 
					 | 
				
			||||||
    protontricks
 | 
					 | 
				
			||||||
    openal
 | 
					 | 
				
			||||||
    gnupg
 | 
					 | 
				
			||||||
    pinentry
 | 
					 | 
				
			||||||
    pinentry-gnome
 | 
					 | 
				
			||||||
    pinentry-curses
 | 
					 | 
				
			||||||
    ncurses
 | 
					 | 
				
			||||||
    monkeysphere
 | 
					 | 
				
			||||||
    gparted
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    virt-viewer
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    inkscape
 | 
					 | 
				
			||||||
    gimp
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    bubblewrap
 | 
					 | 
				
			||||||
    bindfs
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    pulseaudio
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    binutils
 | 
					 | 
				
			||||||
    config.materus.profile.packages.firefox
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  environment.etc = {
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    /*
 | 
					 | 
				
			||||||
      "libvirt/hooks/qemu.d/win11/prepare/begin/start.sh" = {
 | 
					 | 
				
			||||||
      text =
 | 
					 | 
				
			||||||
      ''
 | 
					 | 
				
			||||||
      #!/usr/bin/env bash
 | 
					 | 
				
			||||||
      # Debugging
 | 
					 | 
				
			||||||
      exec 19>/home/materus/startlogfile
 | 
					 | 
				
			||||||
      BASH_XTRACEFD=19
 | 
					 | 
				
			||||||
      set -x
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      exec 3>&1 4>&2
 | 
					 | 
				
			||||||
      trap 'exec 2>&4 1>&3' 0 1 2 3
 | 
					 | 
				
			||||||
      exec 1>/home/materus/startlogfile.out 2>&1
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Stop display manager
 | 
					 | 
				
			||||||
      killall -u materus
 | 
					 | 
				
			||||||
      systemctl stop display-manager.service
 | 
					 | 
				
			||||||
      killall gdm-x-session
 | 
					 | 
				
			||||||
      #systemctl isolate multi-user.target
 | 
					 | 
				
			||||||
      sleep 1
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Load variables we defined
 | 
					 | 
				
			||||||
      source "/etc/libvirt/hooks/kvm.conf"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Isolate host to core 0
 | 
					 | 
				
			||||||
      systemctl set-property --runtime -- user.slice AllowedCPUs=0
 | 
					 | 
				
			||||||
      systemctl set-property --runtime -- system.slice AllowedCPUs=0
 | 
					 | 
				
			||||||
      systemctl set-property --runtime -- init.scope AllowedCPUs=0
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Unbind VTconsoles
 | 
					 | 
				
			||||||
      for (( i = 0; i < 16; i++))
 | 
					 | 
				
			||||||
      do
 | 
					 | 
				
			||||||
      if test -x /sys/class/vtconsole/vtcon"''${i}"; then
 | 
					 | 
				
			||||||
      if [ "$(grep -c "frame buffer" /sys/class/vtconsole/vtcon"''${i}"/name)" = 1 ]; then
 | 
					 | 
				
			||||||
      echo 0 > /sys/class/vtconsole/vtcon"''${i}"/bind
 | 
					 | 
				
			||||||
      echo "$DATE Unbinding Console ''${i}"
 | 
					 | 
				
			||||||
      fi
 | 
					 | 
				
			||||||
      fi
 | 
					 | 
				
			||||||
      done
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Unbind EFI Framebuffer
 | 
					 | 
				
			||||||
      echo "efi-framebuffer.0" > /sys/bus/platform/drivers/efi-framebuffer/unbind
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Avoid race condition
 | 
					 | 
				
			||||||
      sleep 1
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Unload NVIDIA kernel modules
 | 
					 | 
				
			||||||
      modprobe -r nvidia_uvm
 | 
					 | 
				
			||||||
      modprobe -r nvidia_drm
 | 
					 | 
				
			||||||
      modprobe -r nvidia_modeset
 | 
					 | 
				
			||||||
      modprobe -r nvidia
 | 
					 | 
				
			||||||
      modprobe -r i2c_nvidia_gpu
 | 
					 | 
				
			||||||
      modprobe -r drm_kms_helper
 | 
					 | 
				
			||||||
      modprobe -r drm
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Detach GPU devices from host
 | 
					 | 
				
			||||||
      #virsh nodedev-detach $VIRSH_GPU_VIDEO
 | 
					 | 
				
			||||||
      #virsh nodedev-detach $VIRSH_GPU_AUDIO
 | 
					 | 
				
			||||||
      #virsh nodedev-detach $VIRSH_GPU_USB
 | 
					 | 
				
			||||||
      #virsh nodedev-detach $VIRSH_GPU_SERIAL_BUS
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Load vfio module
 | 
					 | 
				
			||||||
      modprobe vfio
 | 
					 | 
				
			||||||
      modprobe vfio_pci
 | 
					 | 
				
			||||||
      modprobe vfio_iommu_type1
 | 
					 | 
				
			||||||
      '';
 | 
					 | 
				
			||||||
      mode = "0755";
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      "libvirt/hooks/qemu.d/win11/release/end/stop.sh" = {
 | 
					 | 
				
			||||||
      text =
 | 
					 | 
				
			||||||
      ''
 | 
					 | 
				
			||||||
      #!/usr/bin/env bash
 | 
					 | 
				
			||||||
      # Debugging
 | 
					 | 
				
			||||||
      exec 19>/home/materus/stoplogfile
 | 
					 | 
				
			||||||
      BASH_XTRACEFD=19
 | 
					 | 
				
			||||||
      set -x
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      exec 3>&1 4>&2
 | 
					 | 
				
			||||||
      trap 'exec 2>&4 1>&3' 0 1 2 3
 | 
					 | 
				
			||||||
      exec 1>/home/materus/stoplogfile.out 2>&1
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Load variables we defined
 | 
					 | 
				
			||||||
      source "/etc/libvirt/hooks/kvm.conf"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Unload vfio module
 | 
					 | 
				
			||||||
      modprobe -r vfio-pci
 | 
					 | 
				
			||||||
      modprobe -r vfio_iommu_type1
 | 
					 | 
				
			||||||
      modprobe -r vfio
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      modprobe drm
 | 
					 | 
				
			||||||
      modprobe drm_kms_helper
 | 
					 | 
				
			||||||
      modprobe i2c_nvidia_gpu
 | 
					 | 
				
			||||||
      modprobe nvidia
 | 
					 | 
				
			||||||
      modprobe nvidia_modeset
 | 
					 | 
				
			||||||
      modprobe nvidia_drm
 | 
					 | 
				
			||||||
      modprobe nvidia_uvm
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Attach GPU devices from host
 | 
					 | 
				
			||||||
      #virsh nodedev-reattach $VIRSH_GPU_VIDEO
 | 
					 | 
				
			||||||
      #virsh nodedev-reattach $VIRSH_GPU_AUDIO
 | 
					 | 
				
			||||||
      #virsh nodedev-reattach $VIRSH_GPU_USB
 | 
					 | 
				
			||||||
      #virsh nodedev-reattach $VIRSH_GPU_SERIAL_BUS
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      #echo "0000:01:00.0" > /sys/bus/pci/drivers/nvidia/bind
 | 
					 | 
				
			||||||
      # Bind EFI Framebuffer
 | 
					 | 
				
			||||||
      echo "efi-framebuffer.0" > /sys/bus/platform/drivers/efi-framebuffer/bind
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Bind VTconsoles
 | 
					 | 
				
			||||||
      echo 1 > /sys/class/vtconsole/vtcon0/bind
 | 
					 | 
				
			||||||
      #echo 1 > /sys/class/vtconsole/vtcon1/bind
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Start display manager
 | 
					 | 
				
			||||||
      sleep 1
 | 
					 | 
				
			||||||
      systemctl start display-manager.service
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      # Return host to all cores
 | 
					 | 
				
			||||||
      systemctl set-property --runtime -- user.slice AllowedCPUs=0-3
 | 
					 | 
				
			||||||
      systemctl set-property --runtime -- system.slice AllowedCPUs=0-3
 | 
					 | 
				
			||||||
      systemctl set-property --runtime -- init.scope AllowedCPUs=0-3
 | 
					 | 
				
			||||||
      '';
 | 
					 | 
				
			||||||
        
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      text = ''
 | 
					 | 
				
			||||||
      #!/usr/bin/env bash
 | 
					 | 
				
			||||||
      reboot
 | 
					 | 
				
			||||||
      '';*-/
 | 
					 | 
				
			||||||
      mode = "0755";
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
      "libvirt/vgabios/patched.rom".source = ./vbios.rom;
 | 
					 | 
				
			||||||
      }; 
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
    */
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,55 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports = [
 | 
					 | 
				
			||||||
    ./win10
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  virtualisation.libvirtd = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    onBoot = "ignore";
 | 
					 | 
				
			||||||
    onShutdown = "shutdown";
 | 
					 | 
				
			||||||
    qemu.ovmf.enable = true;
 | 
					 | 
				
			||||||
    qemu.ovmf.packages = [ pkgs.OVMFFull.fd ];
 | 
					 | 
				
			||||||
    qemu.runAsRoot = true;
 | 
					 | 
				
			||||||
    qemu.swtpm.enable = true;
 | 
					 | 
				
			||||||
    qemu.package = pkgs.qemu_full;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  virtualisation.spiceUSBRedirection.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  environment.systemPackages = with pkgs; [
 | 
					 | 
				
			||||||
    virtiofsd
 | 
					 | 
				
			||||||
    config.virtualisation.libvirtd.qemu.package
 | 
					 | 
				
			||||||
    looking-glass-client
 | 
					 | 
				
			||||||
    virt-manager
 | 
					 | 
				
			||||||
    libguestfs-with-appliance
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  systemd.services.libvirtd = {
 | 
					 | 
				
			||||||
    path =
 | 
					 | 
				
			||||||
      let
 | 
					 | 
				
			||||||
        env = pkgs.buildEnv {
 | 
					 | 
				
			||||||
          name = "qemu-hook-env";
 | 
					 | 
				
			||||||
          paths = with pkgs; [
 | 
					 | 
				
			||||||
            bash
 | 
					 | 
				
			||||||
            libvirt
 | 
					 | 
				
			||||||
            kmod
 | 
					 | 
				
			||||||
            systemd
 | 
					 | 
				
			||||||
            ripgrep
 | 
					 | 
				
			||||||
            sd
 | 
					 | 
				
			||||||
            coreutils
 | 
					 | 
				
			||||||
            sudo
 | 
					 | 
				
			||||||
            su
 | 
					 | 
				
			||||||
            killall
 | 
					 | 
				
			||||||
            procps
 | 
					 | 
				
			||||||
            util-linux
 | 
					 | 
				
			||||||
            bindfs
 | 
					 | 
				
			||||||
            qemu-utils
 | 
					 | 
				
			||||||
            psmisc
 | 
					 | 
				
			||||||
          ];
 | 
					 | 
				
			||||||
        };
 | 
					 | 
				
			||||||
      in
 | 
					 | 
				
			||||||
      [ env ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,128 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  startHook = /*''
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Debugging
 | 
					 | 
				
			||||||
      exec 19>/home/materus/startlogfile
 | 
					 | 
				
			||||||
      BASH_XTRACEFD=19
 | 
					 | 
				
			||||||
      set -x
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      exec 3>&1 4>&2
 | 
					 | 
				
			||||||
      trap 'exec 2>&4 1>&3' 0 1 2 3
 | 
					 | 
				
			||||||
      exec 1>/home/materus/startlogfile.out 2>&1
 | 
					 | 
				
			||||||
    ''
 | 
					 | 
				
			||||||
    +*/
 | 
					 | 
				
			||||||
    ''
 | 
					 | 
				
			||||||
    # Make sure nothing renders on gpu to prevent "sysfs: cannot create duplicate filename" after rebinding to amdgpu
 | 
					 | 
				
			||||||
    chmod 0 /dev/dri/renderD128 
 | 
					 | 
				
			||||||
    fuser -k /dev/dri/renderD128
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Seems to fix reset bug for 7900 XTX
 | 
					 | 
				
			||||||
    echo "0" > "/sys/bus/pci/devices/''${VIRSH_GPU_VIDEO}/d3cold_allowed"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    systemctl stop mountWin10Share.service
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    echo ''$VIRSH_GPU_VIDEO > "/sys/bus/pci/devices/''${VIRSH_GPU_VIDEO}/driver/unbind"
 | 
					 | 
				
			||||||
    echo ''$VIRSH_GPU_AUDIO > "/sys/bus/pci/devices/''${VIRSH_GPU_AUDIO}/driver/unbind"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    sleep 1s
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    echo "10" > "/sys/bus/pci/devices/''${VIRSH_GPU_VIDEO}/resource0_resize"
 | 
					 | 
				
			||||||
    echo "8" > "/sys/bus/pci/devices/''${VIRSH_GPU_VIDEO}/resource2_resize"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    systemctl set-property --runtime -- user.slice AllowedCPUs=12-15,28-31
 | 
					 | 
				
			||||||
    systemctl set-property --runtime -- system.slice AllowedCPUs=12-15,28-31
 | 
					 | 
				
			||||||
    systemctl set-property --runtime -- init.scope AllowedCPUs=12-15,28-31
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  '';
 | 
					 | 
				
			||||||
  stopHook = ''
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Debugging
 | 
					 | 
				
			||||||
    #  exec 19>/home/materus/stoplogfile
 | 
					 | 
				
			||||||
    #  BASH_XTRACEFD=19
 | 
					 | 
				
			||||||
    #  set -x
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    #  exec 3>&1 4>&2
 | 
					 | 
				
			||||||
    #  trap 'exec 2>&4 1>&3' 0 1 2 3
 | 
					 | 
				
			||||||
    #  exec 1>/home/materus/stoplogfile.out 2>&1
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        
 | 
					 | 
				
			||||||
    sleep 1s
 | 
					 | 
				
			||||||
    echo ''$VIRSH_GPU_VIDEO > "/sys/bus/pci/devices/''${VIRSH_GPU_VIDEO}/driver/unbind"
 | 
					 | 
				
			||||||
    echo ''$VIRSH_GPU_AUDIO > "/sys/bus/pci/devices/''${VIRSH_GPU_AUDIO}/driver/unbind"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    echo "15" > "/sys/bus/pci/devices/''${VIRSH_GPU_VIDEO}/resource0_resize"
 | 
					 | 
				
			||||||
    echo "8" > "/sys/bus/pci/devices/''${VIRSH_GPU_VIDEO}/resource2_resize"
 | 
					 | 
				
			||||||
    echo "1" > "/sys/bus/pci/devices/''${VIRSH_GPU_VIDEO}/d3cold_allowed"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    echo ''$VIRSH_GPU_VIDEO > /sys/bus/pci/drivers/amdgpu/bind
 | 
					 | 
				
			||||||
    echo ''$VIRSH_GPU_AUDIO > /sys/bus/pci/drivers/snd_hda_intel/bind
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    systemctl start mountWin10Share.service
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    systemctl set-property --runtime -- user.slice AllowedCPUs=0-31
 | 
					 | 
				
			||||||
    systemctl set-property --runtime -- system.slice AllowedCPUs=0-31
 | 
					 | 
				
			||||||
    systemctl set-property --runtime -- init.scope AllowedCPUs=0-31
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  '';
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  virtualisation.libvirtd.hooks.qemu = {
 | 
					 | 
				
			||||||
    "win10" = pkgs.writeShellScript "win10.sh" ''
 | 
					 | 
				
			||||||
      VIRSH_GPU_VIDEO="0000:03:00.0"
 | 
					 | 
				
			||||||
      VIRSH_GPU_AUDIO="0000:03:00.1"
 | 
					 | 
				
			||||||
      VIRSH_USB1="0000:10:00.0"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      if [ ''$1 = "win10" ] || [ ''$1 = "win11" ]; then
 | 
					 | 
				
			||||||
        if [ ''$2 = "prepare" ] && [ ''$3 = "begin" ]; then
 | 
					 | 
				
			||||||
          ${startHook}
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        if [ ''$2 = "release" ] && [ ''$3 = "end" ]; then
 | 
					 | 
				
			||||||
          ${stopHook}
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  systemd.services.mountWin10Share = {
 | 
					 | 
				
			||||||
    wantedBy = [ "multi-user.target" ];
 | 
					 | 
				
			||||||
    path = [ config.virtualisation.libvirtd.qemu.package pkgs.util-linux pkgs.kmod pkgs.coreutils ];
 | 
					 | 
				
			||||||
    serviceConfig.Type = "oneshot";
 | 
					 | 
				
			||||||
    serviceConfig.RemainAfterExit = true;
 | 
					 | 
				
			||||||
    script = ''
 | 
					 | 
				
			||||||
      modprobe nbd max_part=16
 | 
					 | 
				
			||||||
      sleep 1
 | 
					 | 
				
			||||||
      qemu-nbd -c /dev/nbd0 /materus/data/VM/data.qcow2 --cache=unsafe --discard=unmap
 | 
					 | 
				
			||||||
      sleep 1
 | 
					 | 
				
			||||||
      mount /dev/nbd0p1 /materus/data/Windows -o uid=1000,gid=100
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
    preStop = ''
 | 
					 | 
				
			||||||
      umount /materus/data/Windows
 | 
					 | 
				
			||||||
      qemu-nbd -d /dev/nbd0
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,169 +0,0 @@
 | 
				
			|||||||
# Edit this configuration file to define what should be installed on
 | 
					 | 
				
			||||||
# your system.  Help is available in the configuration.nix(5) man page
 | 
					 | 
				
			||||||
# and in the NixOS manual (accessible by running `nixos-help`).
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
{ config, pkgs, materusFlake, ... }:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports =
 | 
					 | 
				
			||||||
    [
 | 
					 | 
				
			||||||
      # Include the results of the hardware scan.
 | 
					 | 
				
			||||||
      ./hardware-configuration.nix
 | 
					 | 
				
			||||||
      ./pleroma.nix
 | 
					 | 
				
			||||||
          ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  materus.profile.nix.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Use the GRUB 2 boot loader.
 | 
					 | 
				
			||||||
  boot.loader.grub.enable = true;
 | 
					 | 
				
			||||||
  # boot.loader.grub.efiSupport = true;
 | 
					 | 
				
			||||||
  # boot.loader.grub.efiInstallAsRemovable = true;
 | 
					 | 
				
			||||||
  # boot.loader.efi.efiSysMountPoint = "/boot/efi";
 | 
					 | 
				
			||||||
  # Define on which hard drive you want to install Grub.
 | 
					 | 
				
			||||||
  boot.loader.grub.device = "/dev/sda"; # or "nodev" for efi only
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  networking.hostName = "valkyrie"; # Define your hostname.
 | 
					 | 
				
			||||||
  # Pick only one of the below networking options.
 | 
					 | 
				
			||||||
  # networking.wireless.enable = true;  # Enables wireless support via wpa_supplicant.
 | 
					 | 
				
			||||||
  networking.networkmanager.enable = false; # Easiest to use and most distros use this by default.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Set your time zone.
 | 
					 | 
				
			||||||
  time.timeZone = "Europe/Warsaw";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Configure network proxy if necessary
 | 
					 | 
				
			||||||
  # networking.proxy.default = "http://user:password@proxy:port/";
 | 
					 | 
				
			||||||
  # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Select internationalisation properties.
 | 
					 | 
				
			||||||
  i18n.defaultLocale = "pl_PL.UTF-8";
 | 
					 | 
				
			||||||
  console = {
 | 
					 | 
				
			||||||
    font = "lat2-16";
 | 
					 | 
				
			||||||
    keyMap = "pl";
 | 
					 | 
				
			||||||
    useXkbConfig = false; # use xkbOptions in tty.
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable the X11 windowing system.
 | 
					 | 
				
			||||||
  # services.xserver.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Configure keymap in X11
 | 
					 | 
				
			||||||
  # services.xserver.layout = "us";
 | 
					 | 
				
			||||||
  # services.xserver.xkbOptions = "eurosign:e,caps:escape";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable CUPS to print documents.
 | 
					 | 
				
			||||||
  # services.printing.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable sound.
 | 
					 | 
				
			||||||
  # sound.enable = true;
 | 
					 | 
				
			||||||
  # hardware.pulseaudio.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable touchpad support (enabled default in most desktopManager).
 | 
					 | 
				
			||||||
  # services.xserver.libinput.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Define a user account. Don't forget to set a password with ‘passwd’.
 | 
					 | 
				
			||||||
  users.users.materus = {
 | 
					 | 
				
			||||||
    isNormalUser = true;
 | 
					 | 
				
			||||||
    extraGroups = [ "wheel" ]; # Enable ‘sudo’ for the user.
 | 
					 | 
				
			||||||
    packages = with pkgs; [
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
    openssh.authorizedKeys.keyFiles = [ (materusFlake.path + /extraFiles/keys/ssh/materus.pub) ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # List packages installed in system profile. To search, run:
 | 
					 | 
				
			||||||
  # $ nix search wget
 | 
					 | 
				
			||||||
  environment.systemPackages = with pkgs; [
 | 
					 | 
				
			||||||
    vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
 | 
					 | 
				
			||||||
    wget
 | 
					 | 
				
			||||||
    nano
 | 
					 | 
				
			||||||
    git
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Some programs need SUID wrappers, can be configured further or are
 | 
					 | 
				
			||||||
  # started in user sessions.
 | 
					 | 
				
			||||||
  # programs.mtr.enable = true;
 | 
					 | 
				
			||||||
  # programs.gnupg.agent = {
 | 
					 | 
				
			||||||
  #   enable = true;
 | 
					 | 
				
			||||||
  #   enableSSHSupport = true;
 | 
					 | 
				
			||||||
  # };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # List services that you want to enable:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Enable the OpenSSH daemon.
 | 
					 | 
				
			||||||
  services.openssh.enable = true;
 | 
					 | 
				
			||||||
  services.openssh.openFirewall = false;
 | 
					 | 
				
			||||||
  services.openssh.settings.PermitRootLogin = "no";
 | 
					 | 
				
			||||||
  services.openssh.settings.PasswordAuthentication = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.adguardhome.enable = true;
 | 
					 | 
				
			||||||
  # Open ports in the firewall.
 | 
					 | 
				
			||||||
  # networking.firewall.allowedTCPPorts = [ ... ];
 | 
					 | 
				
			||||||
  # networking.firewall.allowedUDPPorts = [ ... ];
 | 
					 | 
				
			||||||
  # Or disable the firewall altogether.
 | 
					 | 
				
			||||||
  networking.firewall.enable = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # Copy the NixOS configuration file and link it from the resulting system
 | 
					 | 
				
			||||||
  # (/run/current-system/configuration.nix). This is useful in case you
 | 
					 | 
				
			||||||
  # accidentally delete configuration.nix.
 | 
					 | 
				
			||||||
  # system.copySystemConfiguration = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # This value determines the NixOS release from which the default
 | 
					 | 
				
			||||||
  # settings for stateful data, like file locations and database versions
 | 
					 | 
				
			||||||
  # on your system were taken. It's perfectly fine and recommended to leave
 | 
					 | 
				
			||||||
  # this value at the release version of the first install of this system.
 | 
					 | 
				
			||||||
  # Before changing this value read the documentation for this option
 | 
					 | 
				
			||||||
  # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
 | 
					 | 
				
			||||||
  system.stateVersion = "23.05"; # Did you read the comment?
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.nginx = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    package = pkgs.tengine;
 | 
					 | 
				
			||||||
    recommendedTlsSettings = true;
 | 
					 | 
				
			||||||
    recommendedOptimisation = true;
 | 
					 | 
				
			||||||
    recommendedGzipSettings = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.postgresql = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    package = pkgs.postgresql_15;
 | 
					 | 
				
			||||||
    enableTCPIP = true;
 | 
					 | 
				
			||||||
    authentication = pkgs.lib.mkOverride 10 ''
 | 
					 | 
				
			||||||
      local all all trust
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  security.acme.acceptTerms = true;
 | 
					 | 
				
			||||||
  security.acme.defaults.email = "materus+acme@podkos.pl";
 | 
					 | 
				
			||||||
  security.acme.certs."materus.pl" = {
 | 
					 | 
				
			||||||
    domain = "materus.pl";
 | 
					 | 
				
			||||||
    group = "nginx";
 | 
					 | 
				
			||||||
    extraDomainNames = [ "*.materus.pl" ];
 | 
					 | 
				
			||||||
    dnsProvider = "ovh";
 | 
					 | 
				
			||||||
    credentialsFile = "/materus/config/valkyrie/certs.secret";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  security.acme.certs."podkos.pl" = {
 | 
					 | 
				
			||||||
    domain = "podkos.pl";
 | 
					 | 
				
			||||||
    group = "nginx";
 | 
					 | 
				
			||||||
    extraDomainNames = [ "*.podkos.pl" ];
 | 
					 | 
				
			||||||
    dnsProvider = "ovh";
 | 
					 | 
				
			||||||
    credentialsFile = "/materus/config/valkyrie/certs.secret";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  security.acme.certs."podkos.xyz" = {
 | 
					 | 
				
			||||||
    domain = "podkos.xyz";
 | 
					 | 
				
			||||||
    group = "nginx";
 | 
					 | 
				
			||||||
    extraDomainNames = [ "*.podkos.xyz" ];
 | 
					 | 
				
			||||||
    dnsProvider = "ovh";
 | 
					 | 
				
			||||||
    credentialsFile = "/materus/config/valkyrie/certs.secret";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
@ -1,16 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, materusPkgs, lib, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  home.stateVersion = "23.05";
 | 
					 | 
				
			||||||
  home.homeDirectory = "/home/materus";
 | 
					 | 
				
			||||||
  materus.profile = {
 | 
					 | 
				
			||||||
    fonts.enable = false;
 | 
					 | 
				
			||||||
    nixpkgs.enable = false;
 | 
					 | 
				
			||||||
    enableDesktop = false;
 | 
					 | 
				
			||||||
    enableTerminal = false;
 | 
					 | 
				
			||||||
    enableTerminalExtra = false;
 | 
					 | 
				
			||||||
    enableNixDevel = false;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    fish.enable = true;
 | 
					 | 
				
			||||||
    bash.enable = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,47 +0,0 @@
 | 
				
			|||||||
# Do not modify this file!  It was generated by ‘nixos-generate-config’
 | 
					 | 
				
			||||||
# and may be overwritten by future invocations.  Please make changes
 | 
					 | 
				
			||||||
# to /etc/nixos/configuration.nix instead.
 | 
					 | 
				
			||||||
{ config, lib, pkgs, modulesPath, ... }:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports =
 | 
					 | 
				
			||||||
    [
 | 
					 | 
				
			||||||
      (modulesPath + "/profiles/qemu-guest.nix")
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  boot.initrd.availableKernelModules = [ "ata_piix" "virtio_pci" "floppy" "sr_mod" "virtio_blk" ];
 | 
					 | 
				
			||||||
  boot.initrd.kernelModules = [ ];
 | 
					 | 
				
			||||||
  boot.kernel.sysctl = { "net.ipv4.ip_forward" = 1; };
 | 
					 | 
				
			||||||
  boot.kernelModules = [ ];
 | 
					 | 
				
			||||||
  boot.extraModulePackages = [ ];
 | 
					 | 
				
			||||||
  boot.tmp.useTmpfs = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/dev/disk/by-uuid/924b1a69-2256-444f-baf6-d2d9405e451d";
 | 
					 | 
				
			||||||
      fsType = "ext4";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  fileSystems."/etc/nixos" =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/materus/config/Nixerus";
 | 
					 | 
				
			||||||
      fsType = "none";
 | 
					 | 
				
			||||||
      options = [ "bind" ];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  swapDevices = [
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
      device = "/swapfile";
 | 
					 | 
				
			||||||
      size = 4 * 1024;
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # 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
 | 
					 | 
				
			||||||
  # still possible to use this option, but it's recommended to use it in conjunction
 | 
					 | 
				
			||||||
  # with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
 | 
					 | 
				
			||||||
  networking.useDHCP = false;
 | 
					 | 
				
			||||||
  networking.nameservers = [ "9.9.9.9" "1.1.1.1" "8.8.8.8" ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,146 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, materusFlake, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  socketPath = "/run/pleroma/http.sock";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  socketChmod = with pkgs; with lib; pkgs.writers.writeBashBin "pleroma-socket"
 | 
					 | 
				
			||||||
    ''
 | 
					 | 
				
			||||||
      coproc {
 | 
					 | 
				
			||||||
          ${inotify-tools}/bin/inotifywait -q -m -e create ${escapeShellArg (dirOf socketPath)}
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        trap 'kill "$COPROC_PID"' EXIT TERM
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        until ${pkgs.coreutils}/bin/test -S ${escapeShellArg socketPath}
 | 
					 | 
				
			||||||
          do read -r -u "''${COPROC[0]}"
 | 
					 | 
				
			||||||
        done
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      ${pkgs.coreutils}/bin/chmod 0666 ${socketPath}
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  soapbox = pkgs.stdenv.mkDerivation rec {
 | 
					 | 
				
			||||||
    pname = "soapbox";
 | 
					 | 
				
			||||||
    version = "v3.2.0";
 | 
					 | 
				
			||||||
    dontBuild = true;
 | 
					 | 
				
			||||||
    dontConfigure = true;
 | 
					 | 
				
			||||||
    src = pkgs.fetchurl {
 | 
					 | 
				
			||||||
      name = "soapbox";
 | 
					 | 
				
			||||||
      url = "https://gitlab.com/soapbox-pub/soapbox/-/jobs/artifacts/${version}/download?job=build-production";
 | 
					 | 
				
			||||||
      sha256 = "sha256-AdW6JK7JkIKLZ8X+N9STeOHqmGNUdhcXyC9jsQPTa9o=";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
    nativeBuildInputs = [pkgs.unzip];
 | 
					 | 
				
			||||||
    unpackPhase = ''
 | 
					 | 
				
			||||||
    unzip $src -d .
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
    installPhase = ''
 | 
					 | 
				
			||||||
    mv ./static $out
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  systemd.tmpfiles.rules = [
 | 
					 | 
				
			||||||
    "d    /var/lib/pleroma   0766    pleroma    pleroma     -"
 | 
					 | 
				
			||||||
    "d    /var/lib/pleroma/static   0766    pleroma    pleroma     -"
 | 
					 | 
				
			||||||
    "d    /var/lib/pleroma/uploads   0766    pleroma    pleroma     -"
 | 
					 | 
				
			||||||
    "L+   /var/lib/pleroma/static/frontends/soapbox/${soapbox.version}  0766 pleroma pleroma - ${soapbox}"
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.nginx.virtualHosts."podkos.xyz" = {
 | 
					 | 
				
			||||||
    http2 = true;
 | 
					 | 
				
			||||||
    useACMEHost = "podkos.xyz";
 | 
					 | 
				
			||||||
    forceSSL = true;
 | 
					 | 
				
			||||||
    locations."/" = {
 | 
					 | 
				
			||||||
      proxyPass = "http://unix:${socketPath}";
 | 
					 | 
				
			||||||
      extraConfig = ''
 | 
					 | 
				
			||||||
        etag on;
 | 
					 | 
				
			||||||
        gzip on;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        add_header 'Access-Control-Allow-Origin' '*' always;
 | 
					 | 
				
			||||||
        add_header 'Access-Control-Allow-Methods' 'POST, PUT, DELETE, GET, PATCH, OPTIONS' always;
 | 
					 | 
				
			||||||
        add_header 'Access-Control-Allow-Headers' 'Authorization, Content-Type, Idempotency-Key' always;
 | 
					 | 
				
			||||||
        add_header 'Access-Control-Expose-Headers' 'Link, X-RateLimit-Reset, X-RateLimit-Limit, X-RateLimit-Remaining, X-Request-Id' always;
 | 
					 | 
				
			||||||
        if ($request_method = OPTIONS) {
 | 
					 | 
				
			||||||
          return 204;
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        add_header X-XSS-Protection "1; mode=block";
 | 
					 | 
				
			||||||
        add_header X-Permitted-Cross-Domain-Policies none;
 | 
					 | 
				
			||||||
        add_header X-Frame-Options DENY;
 | 
					 | 
				
			||||||
        add_header X-Content-Type-Options nosniff;
 | 
					 | 
				
			||||||
        add_header Referrer-Policy same-origin;
 | 
					 | 
				
			||||||
        add_header X-Download-Options noopen;
 | 
					 | 
				
			||||||
        proxy_http_version 1.1;
 | 
					 | 
				
			||||||
        proxy_set_header Upgrade $http_upgrade;
 | 
					 | 
				
			||||||
        proxy_set_header Connection "upgrade";
 | 
					 | 
				
			||||||
        proxy_set_header Host $host;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        client_max_body_size 8m;
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
      '';
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  systemd.services.pleroma.serviceConfig = {
 | 
					 | 
				
			||||||
    RuntimeDirectory = "pleroma";
 | 
					 | 
				
			||||||
    RuntimeDirectoryPreserve = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    ExecStartPost = "${socketChmod}/bin/pleroma-socket";
 | 
					 | 
				
			||||||
    ExecStopPost = ''${pkgs.coreutils}/bin/rm -f ${socketPath}'';
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  services.pleroma = {
 | 
					 | 
				
			||||||
    enable = true;
 | 
					 | 
				
			||||||
    secretConfigFile = "/var/lib/pleroma/secrets.exs";
 | 
					 | 
				
			||||||
    configs = [
 | 
					 | 
				
			||||||
      ''
 | 
					 | 
				
			||||||
        import Config
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        config :pleroma, Pleroma.Web.Endpoint,
 | 
					 | 
				
			||||||
          url: [host: "podkos.xyz", scheme: "https", port: 443],
 | 
					 | 
				
			||||||
          http: [ip: {:local, "${socketPath}"}, port: 0]
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        config :pleroma, :instance,
 | 
					 | 
				
			||||||
          name: "Podziemia Kosmosu",
 | 
					 | 
				
			||||||
          email: "admin@podkos.xyz",
 | 
					 | 
				
			||||||
          notify_email: "noreply@podkos.xyz",
 | 
					 | 
				
			||||||
          limit: 5000,
 | 
					 | 
				
			||||||
          registrations_open: false
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        config :pleroma, :media_proxy,
 | 
					 | 
				
			||||||
          enabled: false,
 | 
					 | 
				
			||||||
          redirect_on_failure: true
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        config :pleroma, Pleroma.Repo,
 | 
					 | 
				
			||||||
          adapter: Ecto.Adapters.Postgres,
 | 
					 | 
				
			||||||
          socket: "/run/postgresql/.s.PGSQL.5432",
 | 
					 | 
				
			||||||
          username: "pleroma",
 | 
					 | 
				
			||||||
          database: "pleroma"
 | 
					 | 
				
			||||||
          
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        # Configure web push notifications
 | 
					 | 
				
			||||||
        config :web_push_encryption, :vapid_details,
 | 
					 | 
				
			||||||
          subject: "mailto:admin@podkos.x yz"
 | 
					 | 
				
			||||||
        config :pleroma, :frontends,
 | 
					 | 
				
			||||||
          primary: %{
 | 
					 | 
				
			||||||
            "name" => "soapbox",
 | 
					 | 
				
			||||||
            "ref" => "${soapbox.version}"
 | 
					 | 
				
			||||||
          }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        config :pleroma, :database, rum_enabled: false
 | 
					 | 
				
			||||||
        config :pleroma, :instance, static_dir: "/var/lib/pleroma/static"
 | 
					 | 
				
			||||||
        config :pleroma, Pleroma.Uploaders.Local, uploads: "/var/lib/pleroma/uploads"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        config :pleroma, configurable_from_database: true  
 | 
					 | 
				
			||||||
        config :pleroma, Pleroma.Upload, filters: [Pleroma.Upload.Filter.AnonymizeFilename]
 | 
					 | 
				
			||||||
      ''
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,10 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, materusFlake, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports = [
 | 
					 | 
				
			||||||
    ./nixpkgs.nix
 | 
					 | 
				
			||||||
    ./packages
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
  config._module.args.materusPkgs = (import materusFlake { inherit pkgs; }) //
 | 
					 | 
				
			||||||
  (if pkgs.system == "x86_64-linux" then { i686Linux = import materusFlake { pkgs = pkgs.pkgsi686Linux; }; } else { });
 | 
					 | 
				
			||||||
  #config.nixpkgs.config.allowUnfree = builtins.trace config.nixpkgs.config.allowUnfree true;
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,22 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, inputs, lib,... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  mkBoolOpt = default: description: lib.mkOption {
 | 
					 | 
				
			||||||
    inherit default;
 | 
					 | 
				
			||||||
    inherit description;
 | 
					 | 
				
			||||||
    type = lib.types.bool;
 | 
					 | 
				
			||||||
    example = true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  cfg = config.materus.profile.nixpkgs;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.nixpkgs.enable = mkBoolOpt false "Enable materus nixpkgs config";
 | 
					 | 
				
			||||||
  options.materus.profile.nixpkgs.enableOverlays = mkBoolOpt (cfg.enable) "Enable materus overlays";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  config.nixpkgs.config = lib.mkIf cfg.enable{
 | 
					 | 
				
			||||||
    allowUnfree = lib.mkDefault true;
 | 
					 | 
				
			||||||
    joypixels.acceptLicense = lib.mkDefault true;
 | 
					 | 
				
			||||||
    firefox.enablePlasmaBrowserIntegration = lib.mkDefault config.services.xserver.desktopManager.plasma5.enable;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  config.nixpkgs.overlays = lib.mkIf cfg.enableOverlays [inputs.emacs-overlay.overlay];
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,49 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusFlake, materusPkgs, ... }:
 | 
					 | 
				
			||||||
with materusPkgs.lib;
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports = [
 | 
					 | 
				
			||||||
    ./fonts.nix
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  #Single Packages
 | 
					 | 
				
			||||||
  options.materus.profile.packages.home-manager = mkPrivateVar inputs.home-manager.packages.${pkgs.system}.home-manager;
 | 
					 | 
				
			||||||
  options.materus.profile.packages.firefox = mkPrivateVar pkgs.firefox;
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  #Package Lists
 | 
					 | 
				
			||||||
  options.materus.profile.packages.list.nixRelated = mkPrivateVar (with pkgs; [
 | 
					 | 
				
			||||||
    nix-prefetch
 | 
					 | 
				
			||||||
    nix-prefetch-scripts
 | 
					 | 
				
			||||||
    nix-prefetch-github
 | 
					 | 
				
			||||||
    nix-prefetch-docker
 | 
					 | 
				
			||||||
    nixfmt
 | 
					 | 
				
			||||||
    nix-top
 | 
					 | 
				
			||||||
    nix-tree
 | 
					 | 
				
			||||||
    nix-diff
 | 
					 | 
				
			||||||
    nix-ld
 | 
					 | 
				
			||||||
    rnix-hashes
 | 
					 | 
				
			||||||
    rnix-lsp
 | 
					 | 
				
			||||||
    nixpkgs-review
 | 
					 | 
				
			||||||
  ]);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  options.materus.profile.packages.list.desktopApps = mkPrivateVar (with pkgs; [
 | 
					 | 
				
			||||||
    barrier
 | 
					 | 
				
			||||||
    (discord.override { nss = nss_latest; withOpenASAR = true; withTTS = true;})
 | 
					 | 
				
			||||||
    tdesktop
 | 
					 | 
				
			||||||
    mpv
 | 
					 | 
				
			||||||
    ani-cli
 | 
					 | 
				
			||||||
    (pkgs.obsidian)
 | 
					 | 
				
			||||||
    spotify
 | 
					 | 
				
			||||||
    thunderbird
 | 
					 | 
				
			||||||
    keepassxc
 | 
					 | 
				
			||||||
    (aspellWithDicts (ds: with ds; [ en en-computers en-science pl ]))
 | 
					 | 
				
			||||||
    onlyoffice-bin
 | 
					 | 
				
			||||||
  ]);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  options.materus.profile.packages.list.terminalApps = mkPrivateVar (with pkgs; [
 | 
					 | 
				
			||||||
    neofetch
 | 
					 | 
				
			||||||
    ripgrep
 | 
					 | 
				
			||||||
    fd
 | 
					 | 
				
			||||||
  ]);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
@ -1,34 +0,0 @@
 | 
				
			|||||||
{ pkgs, lib, ... }:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  defaultFonts = [
 | 
					 | 
				
			||||||
    pkgs.dejavu_fonts
 | 
					 | 
				
			||||||
    pkgs.freefont_ttf
 | 
					 | 
				
			||||||
    pkgs.gyre-fonts
 | 
					 | 
				
			||||||
    pkgs.liberation_ttf
 | 
					 | 
				
			||||||
    pkgs.unifont
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
  fonts = [
 | 
					 | 
				
			||||||
    pkgs.noto-fonts
 | 
					 | 
				
			||||||
    pkgs.noto-fonts-extra
 | 
					 | 
				
			||||||
    pkgs.noto-fonts-emoji
 | 
					 | 
				
			||||||
    pkgs.noto-fonts-cjk-sans
 | 
					 | 
				
			||||||
    pkgs.noto-fonts-cjk-serif
 | 
					 | 
				
			||||||
    pkgs.wqy_zenhei
 | 
					 | 
				
			||||||
    pkgs.corefonts
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
  ] ++ defaultFonts;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  moreFonts = [
 | 
					 | 
				
			||||||
    pkgs.ubuntu_font_family
 | 
					 | 
				
			||||||
    pkgs.monocraft
 | 
					 | 
				
			||||||
    pkgs.hack-font
 | 
					 | 
				
			||||||
    (pkgs.nerdfonts.override { fonts = [ "FiraCode" "DroidSansMono" "Meslo" "ProFont" ]; })
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  options.materus.profile.packages.list.fonts = lib.mkOption { default = fonts; readOnly = true; visible = false; };
 | 
					 | 
				
			||||||
  options.materus.profile.packages.list.moreFonts = lib.mkOption { default = moreFonts; readOnly = true; visible = false; };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,16 +0,0 @@
 | 
				
			|||||||
{
 | 
					 | 
				
			||||||
  osProfile = {
 | 
					 | 
				
			||||||
    imports = [
 | 
					 | 
				
			||||||
      ./os
 | 
					 | 
				
			||||||
      ./common
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  homeProfile = {
 | 
					 | 
				
			||||||
    imports = [
 | 
					 | 
				
			||||||
      ./common
 | 
					 | 
				
			||||||
      ./home
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,21 +0,0 @@
 | 
				
			|||||||
{ config, lib, pkgs, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let 
 | 
					 | 
				
			||||||
cfg = config.materus.profile.browser;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  options= let mkBoolOpt = materusPkgs.lib.mkBoolOpt; in{
 | 
					 | 
				
			||||||
    materus.profile.browser.firefox.enable = mkBoolOpt config.materus.profile.enableDesktop "Enable Firefox with materus cfg";
 | 
					 | 
				
			||||||
    materus.profile.browser.vivaldi.enable = mkBoolOpt config.materus.profile.enableDesktop "Enable Vivaldi with materus cfg";
 | 
					 | 
				
			||||||
    materus.profile.browser.brave.enable = mkBoolOpt  false "Enable Brave with materus cfg";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
  #TODO: Make some config
 | 
					 | 
				
			||||||
  config.home.packages = [
 | 
					 | 
				
			||||||
  (lib.mkIf cfg.firefox.enable config.materus.profile.packages.firefox)
 | 
					 | 
				
			||||||
  (lib.mkIf cfg.vivaldi.enable pkgs.vivaldi)
 | 
					 | 
				
			||||||
  (lib.mkIf cfg.brave.enable pkgs.brave)
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,71 +0,0 @@
 | 
				
			|||||||
{ config, lib, pkgs, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  packages = cfg.packages;
 | 
					 | 
				
			||||||
  cfg = config.materus.profile;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports = [
 | 
					 | 
				
			||||||
    ./fonts.nix
 | 
					 | 
				
			||||||
    ./browser.nix
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    ./shell
 | 
					 | 
				
			||||||
    ./editor
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
  options.materus.profile.enableDesktop = materusPkgs.lib.mkBoolOpt false "Enable settings for desktop";
 | 
					 | 
				
			||||||
  options.materus.profile.enableTerminal = materusPkgs.lib.mkBoolOpt true "Enable settings for terminal";
 | 
					 | 
				
			||||||
  options.materus.profile.enableTerminalExtra = materusPkgs.lib.mkBoolOpt false "Enable extra settings for terminal";
 | 
					 | 
				
			||||||
  options.materus.profile.enableNixDevel = materusPkgs.lib.mkBoolOpt false "Enable settings for nix devel";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  config =
 | 
					 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      home.packages = (if cfg.enableDesktop then packages.list.desktopApps else []) ++
 | 
					 | 
				
			||||||
        (if cfg.enableNixDevel then packages.list.nixRelated else []) ++
 | 
					 | 
				
			||||||
        (if cfg.enableTerminal then packages.list.terminalApps else []);
 | 
					 | 
				
			||||||
      #Desktop
 | 
					 | 
				
			||||||
      programs.feh.enable = lib.mkDefault cfg.enableDesktop;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      #Terminal
 | 
					 | 
				
			||||||
      programs.git = {
 | 
					 | 
				
			||||||
        enable = lib.mkDefault cfg.enableTerminal;
 | 
					 | 
				
			||||||
        package = lib.mkDefault pkgs.gitFull;
 | 
					 | 
				
			||||||
        delta.enable = lib.mkDefault cfg.enableTerminal;
 | 
					 | 
				
			||||||
        lfs.enable = lib.mkDefault cfg.enableTerminal;
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
      programs.gitui.enable = cfg.enableTerminalExtra;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      programs.nix-index = {
 | 
					 | 
				
			||||||
        enable = lib.mkDefault cfg.enableTerminal;
 | 
					 | 
				
			||||||
        enableBashIntegration = lib.mkDefault config.programs.bash.enable;
 | 
					 | 
				
			||||||
        enableFishIntegration = lib.mkDefault config.programs.fish.enable;
 | 
					 | 
				
			||||||
        enableZshIntegration = lib.mkDefault config.programs.zsh.enable;
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      programs.direnv = {
 | 
					 | 
				
			||||||
        enable = lib.mkDefault (cfg.enableTerminalExtra || cfg.enableNixDevel);
 | 
					 | 
				
			||||||
        nix-direnv.enable = lib.mkDefault (cfg.enableNixDevel && (config.programs.direnv.enable == true));
 | 
					 | 
				
			||||||
        enableBashIntegration = lib.mkDefault config.programs.bash.enable;
 | 
					 | 
				
			||||||
        #enableFishIntegration = lib.mkDefault config.programs.fish.enable;
 | 
					 | 
				
			||||||
        enableZshIntegration = lib.mkDefault config.programs.zsh.enable;
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      programs.tmux.enable = lib.mkDefault cfg.enableTerminal;
 | 
					 | 
				
			||||||
      programs.tmux.clock24 = lib.mkDefault config.programs.tmux.enable;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      programs.fzf = {
 | 
					 | 
				
			||||||
        enable = lib.mkDefault cfg.enableTerminalExtra;
 | 
					 | 
				
			||||||
        enableBashIntegration = lib.mkDefault config.programs.bash.enable;
 | 
					 | 
				
			||||||
        enableFishIntegration = lib.mkDefault config.programs.fish.enable;
 | 
					 | 
				
			||||||
        enableZshIntegration = lib.mkDefault config.programs.zsh.enable;
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      programs.exa.enable = lib.mkDefault cfg.enableTerminalExtra;
 | 
					 | 
				
			||||||
      programs.exa.enableAliases = lib.mkDefault config.programs.exa.enable;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      programs.yt-dlp.enable = lib.mkDefault cfg.enableTerminalExtra;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,17 +0,0 @@
 | 
				
			|||||||
{ config, lib, pkgs, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  cfg = config.materus.profile.editor.code;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.editor.code.enable = materusPkgs.lib.mkBoolOpt config.materus.profile.enableDesktop "Enable VSCodium with materus cfg";
 | 
					 | 
				
			||||||
  options.materus.profile.editor.code.fhs.enable = materusPkgs.lib.mkBoolOpt false "Use fhs vscodium";
 | 
					 | 
				
			||||||
  options.materus.profile.editor.code.fhs.packages = lib.mkOption { default = (ps: []);};
 | 
					 | 
				
			||||||
  config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
    programs.vscode = {
 | 
					 | 
				
			||||||
      enable = lib.mkDefault true;
 | 
					 | 
				
			||||||
      package = lib.mkDefault (if (cfg.fhs.enable)  then (pkgs.vscodium.fhsWithPackages cfg.fhs.packages) else pkgs.vscodium);
 | 
					 | 
				
			||||||
      mutableExtensionsDir = lib.mkDefault true;
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
    materus.profile.fonts.enable = lib.mkDefault true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,8 +0,0 @@
 | 
				
			|||||||
{ config, lib, pkgs, ... }:
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  imports = [
 | 
					 | 
				
			||||||
    ./code.nix
 | 
					 | 
				
			||||||
    ./neovim.nix
 | 
					 | 
				
			||||||
    ./emacs.nix
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,25 +0,0 @@
 | 
				
			|||||||
{ config, lib, pkgs, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  cfg = config.materus.profile.editor.emacs;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.editor.emacs.enable = materusPkgs.lib.mkBoolOpt false "Enable emacs with materus cfg";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
    #TODO: Make config
 | 
					 | 
				
			||||||
    /*home.activation.doomEmacs = lib.hm.dag.entryBetween [ "onFilesChange" ] [ "writeBoundry" ] ''
 | 
					 | 
				
			||||||
      if [ ! -d ~/.emacs.d ] ; 
 | 
					 | 
				
			||||||
        then ${pkgs.git}/bin/git clone --depth 1 https://github.com/doomemacs/doomemacs ~/.emacs.d 
 | 
					 | 
				
			||||||
      fi
 | 
					 | 
				
			||||||
      PATH="${config.programs.git.package}/bin:${config.programs.emacs.package}/bin:$PATH"
 | 
					 | 
				
			||||||
      ~/.emacs.d/bin/doom sync
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    home.file.doomEmacs.source = "${materusArg.flakeData.extraFiles}/config/emacs/doom";
 | 
					 | 
				
			||||||
    home.file.doomEmacs.target = "${config.xdg.configHome}/doom";*/
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    programs.emacs.enable = true;
 | 
					 | 
				
			||||||
    programs.emacs.package = with pkgs; lib.mkDefault (if pkgs ? emacsUnstablePgtk then emacsUnstablePgtk else emacs-gtk);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,54 +0,0 @@
 | 
				
			|||||||
{ config, lib, pkgs, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
cfg = config.materus.profile.editor.neovim;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.editor.neovim.enable = materusPkgs.lib.mkBoolOpt config.materus.profile.enableTerminalExtra "Enable neovim with materus cfg";
 | 
					 | 
				
			||||||
  config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
    programs.neovim = {
 | 
					 | 
				
			||||||
      enable = true;
 | 
					 | 
				
			||||||
      coc.enable = true;
 | 
					 | 
				
			||||||
      viAlias = true;
 | 
					 | 
				
			||||||
      vimAlias = true;
 | 
					 | 
				
			||||||
      vimdiffAlias = true;
 | 
					 | 
				
			||||||
      withNodeJs = true;
 | 
					 | 
				
			||||||
      withPython3 = true;
 | 
					 | 
				
			||||||
      withRuby = true;
 | 
					 | 
				
			||||||
      defaultEditor = true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      extraConfig = ''
 | 
					 | 
				
			||||||
      set number
 | 
					 | 
				
			||||||
      '';
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    plugins = with pkgs.vimPlugins;[
 | 
					 | 
				
			||||||
      nerdtree
 | 
					 | 
				
			||||||
      syntastic
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      vim-fugitive
 | 
					 | 
				
			||||||
      vim-airline
 | 
					 | 
				
			||||||
      vim-nix
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      nvim-fzf
 | 
					 | 
				
			||||||
      nvim-treesitter.withAllGrammars
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
      coc-clangd
 | 
					 | 
				
			||||||
      coc-python
 | 
					 | 
				
			||||||
      coc-pyright
 | 
					 | 
				
			||||||
      coc-sh
 | 
					 | 
				
			||||||
      coc-git
 | 
					 | 
				
			||||||
      coc-css
 | 
					 | 
				
			||||||
      coc-yaml
 | 
					 | 
				
			||||||
      coc-toml
 | 
					 | 
				
			||||||
      coc-json
 | 
					 | 
				
			||||||
      coc-html
 | 
					 | 
				
			||||||
      coc-highlight
 | 
					 | 
				
			||||||
      coc-java
 | 
					 | 
				
			||||||
      coc-cmake
 | 
					 | 
				
			||||||
      coc-vimlsp
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,13 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  packages = config.materus.profile.packages;
 | 
					 | 
				
			||||||
  cfg = config.materus.profile.fonts;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.fonts.enable = materusPkgs.lib.mkBoolOpt config.materus.profile.enableDesktop "Enable materus font settings";
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
  config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
    fonts.fontconfig.enable = lib.mkDefault true;
 | 
					 | 
				
			||||||
    home.packages = packages.list.fonts;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,20 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, materusFlake, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let 
 | 
					 | 
				
			||||||
cfg = config.materus.profile.bash;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    options.materus.profile.bash.enable = materusPkgs.lib.mkBoolOpt config.materus.profile.enableTerminal "Enable materus bash config";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      programs.bash = {
 | 
					 | 
				
			||||||
        enable = lib.mkDefault true;
 | 
					 | 
				
			||||||
        enableCompletion = lib.mkDefault true;
 | 
					 | 
				
			||||||
        enableVteIntegration = lib.mkDefault true;
 | 
					 | 
				
			||||||
        historyControl = lib.mkDefault ["erasedups" "ignorespace"];
 | 
					 | 
				
			||||||
        shellOptions = lib.mkDefault [ "autocd" "checkwinsize" "cmdhist" "expand_aliases" "extglob" "globstar" "checkjobs" "nocaseglob" ];
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,9 +0,0 @@
 | 
				
			|||||||
{
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  imports = [ 
 | 
					 | 
				
			||||||
    ./zsh.nix
 | 
					 | 
				
			||||||
    ./bash.nix
 | 
					 | 
				
			||||||
    ./fish.nix
 | 
					 | 
				
			||||||
    ./starship.nix
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,12 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, materusFlake, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let 
 | 
					 | 
				
			||||||
cfg = config.materus.profile.fish;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.fish.enable = materusPkgs.lib.mkBoolOpt config.materus.profile.enableTerminalExtra "Enable materus fish config";
 | 
					 | 
				
			||||||
  config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
    programs.fish = {
 | 
					 | 
				
			||||||
      enable = lib.mkDefault true;
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,48 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, materusFlake, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  profile = config.materus.profile;
 | 
					 | 
				
			||||||
  cfg = config.materus.profile.starship;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.starship.enable = materusPkgs.lib.mkBoolOpt (profile.zsh.enable || profile.bash.enable || profile.fish.enable) "Enable materus fish config";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
    programs.starship.enable = lib.mkDefault cfg.enable;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    programs.starship.settings = {
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      python = {
 | 
					 | 
				
			||||||
        symbol = " ";
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      format = "$username@$hostname$all";
 | 
					 | 
				
			||||||
      right_format = "$cmd_duration $time";
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
      time = {
 | 
					 | 
				
			||||||
        disabled = false;
 | 
					 | 
				
			||||||
        style = "bold bright-black";
 | 
					 | 
				
			||||||
        format = "[$time]($style)";
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      line_break = { disabled = true; };
 | 
					 | 
				
			||||||
      shell = {
 | 
					 | 
				
			||||||
        disabled = false;
 | 
					 | 
				
			||||||
        fish_indicator = "fish";
 | 
					 | 
				
			||||||
        bash_indicator= "bash";
 | 
					 | 
				
			||||||
        zsh_indicator= "zsh";
 | 
					 | 
				
			||||||
        style = "blue bold";
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      hostname = {
 | 
					 | 
				
			||||||
        ssh_only = false;
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
      username = {
 | 
					 | 
				
			||||||
        disabled = false;
 | 
					 | 
				
			||||||
        show_always = true;
 | 
					 | 
				
			||||||
        format = "[$user]($style)";
 | 
					 | 
				
			||||||
        style_user = "white bold";
 | 
					 | 
				
			||||||
        style_root = "black bold";
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,96 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, materusFlake, materusPkgs, options, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  p10kcfg = "${zshcfg}/p10kcfg";
 | 
					 | 
				
			||||||
  zshcfg = "${materusFlake.path}/extraFiles/config/zsh";
 | 
					 | 
				
			||||||
  cfg = config.materus.profile.zsh;
 | 
					 | 
				
			||||||
  enableStarship = config.materus.starship.enable;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.zsh.enable = materusPkgs.lib.mkBoolOpt config.materus.profile.enableTerminalExtra "Enable materus zsh config";
 | 
					 | 
				
			||||||
  options.materus.profile.zsh.prompt = lib.mkOption {
 | 
					 | 
				
			||||||
      type = lib.types.enum ["p10k" "starship"];
 | 
					 | 
				
			||||||
      example = "p10k";
 | 
					 | 
				
			||||||
      default = "p10k";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
    home.packages = [
 | 
					 | 
				
			||||||
      pkgs.ripgrep
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    programs.zsh = {
 | 
					 | 
				
			||||||
      enable = true;
 | 
					 | 
				
			||||||
      enableAutosuggestions = true;
 | 
					 | 
				
			||||||
      enableSyntaxHighlighting = true;
 | 
					 | 
				
			||||||
      enableVteIntegration = true;
 | 
					 | 
				
			||||||
      historySubstringSearch.enable = true;
 | 
					 | 
				
			||||||
      historySubstringSearch.searchUpKey = ";5A";
 | 
					 | 
				
			||||||
      historySubstringSearch.searchDownKey = ";5B";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      envExtra = ''
 | 
					 | 
				
			||||||
        if [[ -z "$__MATERUS_HM_ZSH" ]]; then
 | 
					 | 
				
			||||||
          __MATERUS_HM_ZSH=1
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
        if [[ -z "$__MATERUS_HM_ZSH_PROMPT" ]]; then
 | 
					 | 
				
			||||||
          __MATERUS_HM_ZSH_PROMPT=${cfg.prompt}
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
      '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      initExtraFirst = lib.mkIf (cfg.prompt == "p10k" ) ''
 | 
					 | 
				
			||||||
        if [[ -r "''${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-''${(%):-%n}.zsh" ]]; then
 | 
					 | 
				
			||||||
          source "''${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-''${(%):-%n}.zsh"
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
      '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      plugins = [
 | 
					 | 
				
			||||||
        (lib.mkIf (cfg.prompt == "p10k" ) {
 | 
					 | 
				
			||||||
          name = "powerlevel10k";
 | 
					 | 
				
			||||||
          src = pkgs.fetchFromGitHub {
 | 
					 | 
				
			||||||
            owner = "romkatv";
 | 
					 | 
				
			||||||
            repo = "powerlevel10k";
 | 
					 | 
				
			||||||
            rev = "bc5983543a10cff2eac30cced9208bbfd91428b8";
 | 
					 | 
				
			||||||
            sha256 = "0s8ndbpmlqakg7s7hryyi1pqij1h5dv0xv9xvr2qwwyhyj6zrx2i";
 | 
					 | 
				
			||||||
          };
 | 
					 | 
				
			||||||
          file = "powerlevel10k.zsh-theme";
 | 
					 | 
				
			||||||
        })
 | 
					 | 
				
			||||||
      ];
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
      history = {
 | 
					 | 
				
			||||||
        extended = true;
 | 
					 | 
				
			||||||
        save = 100000;
 | 
					 | 
				
			||||||
        size = 100000;
 | 
					 | 
				
			||||||
        share = false;
 | 
					 | 
				
			||||||
        ignoreDups = true;
 | 
					 | 
				
			||||||
        ignoreSpace = true;
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      initExtra = ''
 | 
					 | 
				
			||||||
        . ${zshcfg}/zinputrc
 | 
					 | 
				
			||||||
        source ${zshcfg}/zshcompletion.zsh
 | 
					 | 
				
			||||||
        
 | 
					 | 
				
			||||||
        bindkey -r "^["
 | 
					 | 
				
			||||||
        bindkey ";5C" forward-word
 | 
					 | 
				
			||||||
        bindkey ";5D" backward-word
 | 
					 | 
				
			||||||
        '' +
 | 
					 | 
				
			||||||
        (if (cfg.prompt == "p10k" ) then
 | 
					 | 
				
			||||||
        ''
 | 
					 | 
				
			||||||
        if zmodload zsh/terminfo && (( terminfo[colors] >= 256 )); then
 | 
					 | 
				
			||||||
          [[ ! -f ${p10kcfg}/fullcolor.zsh ]] || source ${p10kcfg}/fullcolor.zsh
 | 
					 | 
				
			||||||
        else
 | 
					 | 
				
			||||||
          [[ ! -f ${p10kcfg}/compatibility.zsh ]] || source ${p10kcfg}/compatibility.zsh
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
      '' else "");
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    programs.starship.enableZshIntegration = lib.mkForce false; 
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,9 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, ... }:
 | 
					 | 
				
			||||||
{ 
 | 
					 | 
				
			||||||
  imports = [
 | 
					 | 
				
			||||||
    ./nix.nix
 | 
					 | 
				
			||||||
    ./fonts.nix
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    ./games
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,24 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  packages = config.materus.profile.packages;
 | 
					 | 
				
			||||||
  cfg = config.materus.profile.fonts;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.fonts.enable = materusPkgs.lib.mkBoolOpt false "Enable materus font settings for OS";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    fonts.fonts = packages.list.fonts ++ packages.list.moreFonts;
 | 
					 | 
				
			||||||
    fonts.enableDefaultFonts = lib.mkForce true;
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    fonts.fontconfig.enable = lib.mkForce true;
 | 
					 | 
				
			||||||
    fonts.fontconfig.cache32Bit = lib.mkForce  true;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    fonts.fontconfig.defaultFonts.sansSerif =  [ "Noto Sans" "DejaVu Sans" "WenQuanYi Zen Hei" "Noto Color Emoji" ];
 | 
					 | 
				
			||||||
    fonts.fontconfig.defaultFonts.serif =  [ "Noto Serif" "DejaVu Serif" "WenQuanYi Zen Hei" "Noto Color Emoji" ];
 | 
					 | 
				
			||||||
    fonts.fontconfig.defaultFonts.emoji =  [ "Noto Color Emoji" "OpenMoji Color" ];
 | 
					 | 
				
			||||||
    fonts.fontconfig.defaultFonts.monospace =  [ "FiraCode Nerd Font Mono" "Noto Sans Mono" "WenQuanYi Zen Hei Mono" ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    fonts.fontDir.enable = lib.mkForce true;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,6 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, ... }:
 | 
					 | 
				
			||||||
{ 
 | 
					 | 
				
			||||||
  imports = [
 | 
					 | 
				
			||||||
    ./steam.nix
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,125 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, materusPkgs, inputs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  optHip = pkgs.stdenv.mkDerivation rec {
 | 
					 | 
				
			||||||
  pname = "optHip";
 | 
					 | 
				
			||||||
  version = pkgs.hip.version;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  dontFixup = true;
 | 
					 | 
				
			||||||
  dontBuild = true;
 | 
					 | 
				
			||||||
  dontPatchELF = true;
 | 
					 | 
				
			||||||
  dontUnpack = true;
 | 
					 | 
				
			||||||
  sourceRoot = ".";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  buildInputs = [
 | 
					 | 
				
			||||||
    pkgs.hip
 | 
					 | 
				
			||||||
  ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  installPhase = ''
 | 
					 | 
				
			||||||
    mkdir -p $out/opt/rocm
 | 
					 | 
				
			||||||
    ln -s ${pkgs.hip} $out/opt/rocm/hip
 | 
					 | 
				
			||||||
  '';
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  steamPkg = pkgs.steam.override {
 | 
					 | 
				
			||||||
    extraPkgs = pkgs: [
 | 
					 | 
				
			||||||
      config.materus.profile.packages.firefox
 | 
					 | 
				
			||||||
      optHip #for blender
 | 
					 | 
				
			||||||
      pkgs.steamcmd
 | 
					 | 
				
			||||||
      pkgs.nss_latest
 | 
					 | 
				
			||||||
      pkgs.libstrangle
 | 
					 | 
				
			||||||
      pkgs.libkrb5
 | 
					 | 
				
			||||||
      pkgs.keyutils
 | 
					 | 
				
			||||||
      pkgs.libGL
 | 
					 | 
				
			||||||
      pkgs.libglvnd
 | 
					 | 
				
			||||||
      pkgs.gamescope
 | 
					 | 
				
			||||||
      pkgs.steamPackages.steam
 | 
					 | 
				
			||||||
      pkgs.libxcrypt
 | 
					 | 
				
			||||||
      pkgs.gnutls
 | 
					 | 
				
			||||||
      pkgs.xorg.libXcursor
 | 
					 | 
				
			||||||
      pkgs.xorg.libXi
 | 
					 | 
				
			||||||
      pkgs.xorg.libXinerama
 | 
					 | 
				
			||||||
      pkgs.xorg.libXScrnSaver
 | 
					 | 
				
			||||||
      pkgs.xorg.xinput
 | 
					 | 
				
			||||||
      pkgs.xorg.xcbutilwm
 | 
					 | 
				
			||||||
      pkgs.xorg.xcbutilimage
 | 
					 | 
				
			||||||
      pkgs.xorg.xcbutilkeysyms
 | 
					 | 
				
			||||||
      pkgs.xorg.xcbutilerrors
 | 
					 | 
				
			||||||
      pkgs.xorg.xcbutilrenderutil
 | 
					 | 
				
			||||||
      pkgs.xorg.xcbutil
 | 
					 | 
				
			||||||
      pkgs.xorg.xwininfo
 | 
					 | 
				
			||||||
      pkgs.yad
 | 
					 | 
				
			||||||
      pkgs.xdotool
 | 
					 | 
				
			||||||
      pkgs.libinput
 | 
					 | 
				
			||||||
      pkgs.openvdb
 | 
					 | 
				
			||||||
      pkgs.openssl
 | 
					 | 
				
			||||||
      pkgs.tbb_2021_8
 | 
					 | 
				
			||||||
      pkgs.gtk4
 | 
					 | 
				
			||||||
      pkgs.gtk3
 | 
					 | 
				
			||||||
      pkgs.glib
 | 
					 | 
				
			||||||
      pkgs.gsettings-desktop-schemas
 | 
					 | 
				
			||||||
      pkgs.fuse
 | 
					 | 
				
			||||||
      pkgs.libsForQt5.breeze-qt5
 | 
					 | 
				
			||||||
      pkgs.libsForQt5.breeze-gtk
 | 
					 | 
				
			||||||
      pkgs.libsForQt5.dolphin
 | 
					 | 
				
			||||||
      pkgs.samba4Full
 | 
					 | 
				
			||||||
      pkgs.tdb
 | 
					 | 
				
			||||||
      pkgs.jbig2enc
 | 
					 | 
				
			||||||
      pkgs.jbig2dec
 | 
					 | 
				
			||||||
      pkgs.vivaldi
 | 
					 | 
				
			||||||
      pkgs.x264.lib
 | 
					 | 
				
			||||||
      pkgs.steamtinkerlaunch
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    ] ++ config.materus.profile.packages.list.fonts;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    extraLibraries = pkgs: [
 | 
					 | 
				
			||||||
      pkgs.libkrb5
 | 
					 | 
				
			||||||
      pkgs.keyutils
 | 
					 | 
				
			||||||
      pkgs.ncurses6
 | 
					 | 
				
			||||||
      pkgs.xorg.xinput
 | 
					 | 
				
			||||||
      pkgs.libinput
 | 
					 | 
				
			||||||
      pkgs.fontconfig
 | 
					 | 
				
			||||||
      pkgs.libxcrypt
 | 
					 | 
				
			||||||
      pkgs.gnutls
 | 
					 | 
				
			||||||
      pkgs.samba 
 | 
					 | 
				
			||||||
      pkgs.tdb
 | 
					 | 
				
			||||||
    ] ++
 | 
					 | 
				
			||||||
    (with config.hardware.opengl; if pkgs.hostPlatform.is64bit
 | 
					 | 
				
			||||||
    then [ package ] ++ extraPackages
 | 
					 | 
				
			||||||
    else [ package32 ] ++ extraPackages32);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    extraEnv = {
 | 
					 | 
				
			||||||
      XDG_DATA_DIRS = "/usr/share:\${XDG_DATA_DIRS}";
 | 
					 | 
				
			||||||
      OBS_VKCAPTURE = "1";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  cfg = config.materus.profile.steam;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.steam.enable = materusPkgs.lib.mkBoolOpt false "Enable materus steam settings for OS";
 | 
					 | 
				
			||||||
  options.materus.profile.steam.package = lib.mkOption {
 | 
					 | 
				
			||||||
    type = lib.types.package;
 | 
					 | 
				
			||||||
    default = steamPkg;
 | 
					 | 
				
			||||||
    description = "Package used by steam";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  config = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
    hardware.steam-hardware.enable = lib.mkDefault true;
 | 
					 | 
				
			||||||
    programs.steam = {
 | 
					 | 
				
			||||||
      enable = lib.mkDefault true;
 | 
					 | 
				
			||||||
      dedicatedServer.openFirewall = lib.mkDefault true;
 | 
					 | 
				
			||||||
      remotePlay.openFirewall = lib.mkDefault true;
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
    environment.sessionVariables = rec {
 | 
					 | 
				
			||||||
      STEAM_EXTRA_COMPAT_TOOLS_PATHS = lib.mkDefault "\${HOME}/.steam/root/compatibilitytools.d";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
    environment.systemPackages = [
 | 
					 | 
				
			||||||
      steamPkg
 | 
					 | 
				
			||||||
      steamPkg.run
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,23 +0,0 @@
 | 
				
			|||||||
{ config, pkgs, lib, inputs, materusPkgs, ... }:
 | 
					 | 
				
			||||||
let
 | 
					 | 
				
			||||||
  cfg = config.materus.profile.nix;
 | 
					 | 
				
			||||||
in
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
  options.materus.profile.nix.enable = materusPkgs.lib.mkBoolOpt false "Enable materus nix settings";
 | 
					 | 
				
			||||||
  config.nix = lib.mkIf cfg.enable {
 | 
					 | 
				
			||||||
    package = lib.mkDefault pkgs.nixVersions.unstable;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    settings = {
 | 
					 | 
				
			||||||
      experimental-features = [ "nix-command" "flakes" "repl-flake" "no-url-literals" ];
 | 
					 | 
				
			||||||
      auto-optimise-store = true;
 | 
					 | 
				
			||||||
      trusted-users = [ "root" "@wheel" ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      substituters = [
 | 
					 | 
				
			||||||
        "https://nix-community.cachix.org"
 | 
					 | 
				
			||||||
        "https://cache.nixos.org/"
 | 
					 | 
				
			||||||
        "https://nixerus.cachix.org/"
 | 
					 | 
				
			||||||
      ];
 | 
					 | 
				
			||||||
      trusted-public-keys = [ "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" "nixerus.cachix.org-1:2x7sIG7y1vAoxc8BNRJwsfapZsiX4hIl4aTi9V5ZDdE="];
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@ -1,76 +0,0 @@
 | 
				
			|||||||
;;; $DOOMDIR/config.el -*- lexical-binding: t; -*-
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; Place your private configuration here! Remember, you do not need to run 'doom
 | 
					 | 
				
			||||||
;; sync' after modifying this file!
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; Some functionality uses this to identify you, e.g. GPG configuration, email
 | 
					 | 
				
			||||||
;; clients, file templates and snippets. It is optional.
 | 
					 | 
				
			||||||
(setq user-full-name "John Doe"
 | 
					 | 
				
			||||||
      user-mail-address "john@doe.com")
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; Doom exposes five (optional) variables for controlling fonts in Doom:
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;; - `doom-font' -- the primary font to use
 | 
					 | 
				
			||||||
;; - `doom-variable-pitch-font' -- a non-monospace font (where applicable)
 | 
					 | 
				
			||||||
;; - `doom-big-font' -- used for `doom-big-font-mode'; use this for
 | 
					 | 
				
			||||||
;;   presentations or streaming.
 | 
					 | 
				
			||||||
;; - `doom-unicode-font' -- for unicode glyphs
 | 
					 | 
				
			||||||
;; - `doom-serif-font' -- for the `fixed-pitch-serif' face
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;; See 'C-h v doom-font' for documentation and more examples of what they
 | 
					 | 
				
			||||||
;; accept. For example:
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;;(setq doom-font (font-spec :family "Fira Code" :size 12 :weight 'semi-light)
 | 
					 | 
				
			||||||
;;      doom-variable-pitch-font (font-spec :family "Fira Sans" :size 13))
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;; If you or Emacs can't find your font, use 'M-x describe-font' to look them
 | 
					 | 
				
			||||||
;; up, `M-x eval-region' to execute elisp code, and 'M-x doom/reload-font' to
 | 
					 | 
				
			||||||
;; refresh your font settings. If Emacs still can't find your font, it likely
 | 
					 | 
				
			||||||
;; wasn't installed correctly. Font issues are rarely Doom issues!
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; There are two ways to load a theme. Both assume the theme is installed and
 | 
					 | 
				
			||||||
;; available. You can either set `doom-theme' or manually load a theme with the
 | 
					 | 
				
			||||||
;; `load-theme' function. This is the default:
 | 
					 | 
				
			||||||
(setq doom-theme 'doom-one)
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; This determines the style of line numbers in effect. If set to `nil', line
 | 
					 | 
				
			||||||
;; numbers are disabled. For relative line numbers, set this to `relative'.
 | 
					 | 
				
			||||||
(setq display-line-numbers-type t)
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; If you use `org' and don't want your org files in the default location below,
 | 
					 | 
				
			||||||
;; change `org-directory'. It must be set before org loads!
 | 
					 | 
				
			||||||
(setq org-directory "~/org/")
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; Whenever you reconfigure a package, make sure to wrap your config in an
 | 
					 | 
				
			||||||
;; `after!' block, otherwise Doom's defaults may override your settings. E.g.
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;;   (after! PACKAGE
 | 
					 | 
				
			||||||
;;     (setq x y))
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;; The exceptions to this rule:
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;;   - Setting file/directory variables (like `org-directory')
 | 
					 | 
				
			||||||
;;   - Setting variables which explicitly tell you to set them before their
 | 
					 | 
				
			||||||
;;     package is loaded (see 'C-h v VARIABLE' to look up their documentation).
 | 
					 | 
				
			||||||
;;   - Setting doom variables (which start with 'doom-' or '+').
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;; Here are some additional functions/macros that will help you configure Doom.
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;; - `load!' for loading external *.el files relative to this one
 | 
					 | 
				
			||||||
;; - `use-package!' for configuring packages
 | 
					 | 
				
			||||||
;; - `after!' for running code after a package has loaded
 | 
					 | 
				
			||||||
;; - `add-load-path!' for adding directories to the `load-path', relative to
 | 
					 | 
				
			||||||
;;   this file. Emacs searches the `load-path' when you load packages with
 | 
					 | 
				
			||||||
;;   `require' or `use-package'.
 | 
					 | 
				
			||||||
;; - `map!' for binding new keys
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;; To get information about any of these functions/macros, move the cursor over
 | 
					 | 
				
			||||||
;; the highlighted symbol at press 'K' (non-evil users must press 'C-c c k').
 | 
					 | 
				
			||||||
;; This will open documentation for it, including demos of how they are used.
 | 
					 | 
				
			||||||
;; Alternatively, use `C-h o' to look up a symbol (functions, variables, faces,
 | 
					 | 
				
			||||||
;; etc).
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;; You can also try 'gd' (or 'C-c c d') to jump to their definition and see how
 | 
					 | 
				
			||||||
;; they are implemented.
 | 
					 | 
				
			||||||
@ -1,194 +0,0 @@
 | 
				
			|||||||
;;; init.el -*- lexical-binding: t; -*-
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; This file controls what Doom modules are enabled and what order they load
 | 
					 | 
				
			||||||
;; in. Remember to run 'doom sync' after modifying it!
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; NOTE Press 'SPC h d h' (or 'C-h d h' for non-vim users) to access Doom's
 | 
					 | 
				
			||||||
;;      documentation. There you'll find a link to Doom's Module Index where all
 | 
					 | 
				
			||||||
;;      of our modules are listed, including what flags they support.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; NOTE Move your cursor over a module's name (or its flags) and press 'K' (or
 | 
					 | 
				
			||||||
;;      'C-c c k' for non-vim users) to view its documentation. This works on
 | 
					 | 
				
			||||||
;;      flags as well (those symbols that start with a plus).
 | 
					 | 
				
			||||||
;;
 | 
					 | 
				
			||||||
;;      Alternatively, press 'gd' (or 'C-c c d') on a module to browse its
 | 
					 | 
				
			||||||
;;      directory (for easy access to its source code).
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
(doom! :input
 | 
					 | 
				
			||||||
       ;;bidi              ; (tfel ot) thgir etirw uoy gnipleh
 | 
					 | 
				
			||||||
       ;;chinese
 | 
					 | 
				
			||||||
       ;;japanese
 | 
					 | 
				
			||||||
       ;;layout            ; auie,ctsrnm is the superior home row
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :completion
 | 
					 | 
				
			||||||
       company           ; the ultimate code completion backend
 | 
					 | 
				
			||||||
       ;;helm              ; the *other* search engine for love and life
 | 
					 | 
				
			||||||
       ;;ido               ; the other *other* search engine...
 | 
					 | 
				
			||||||
       ;;ivy               ; a search engine for love and life
 | 
					 | 
				
			||||||
       vertico           ; the search engine of the future
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :ui
 | 
					 | 
				
			||||||
       ;;deft              ; notational velocity for Emacs
 | 
					 | 
				
			||||||
       doom              ; what makes DOOM look the way it does
 | 
					 | 
				
			||||||
       doom-dashboard    ; a nifty splash screen for Emacs
 | 
					 | 
				
			||||||
       ;;doom-quit         ; DOOM quit-message prompts when you quit Emacs
 | 
					 | 
				
			||||||
       ;;(emoji +unicode)  ; 🙂
 | 
					 | 
				
			||||||
       hl-todo           ; highlight TODO/FIXME/NOTE/DEPRECATED/HACK/REVIEW
 | 
					 | 
				
			||||||
       ;;hydra
 | 
					 | 
				
			||||||
       ;;indent-guides     ; highlighted indent columns
 | 
					 | 
				
			||||||
       ligatures         ; ligatures and symbols to make your code pretty again
 | 
					 | 
				
			||||||
       ;;minimap           ; show a map of the code on the side
 | 
					 | 
				
			||||||
       modeline          ; snazzy, Atom-inspired modeline, plus API
 | 
					 | 
				
			||||||
       ;;nav-flash         ; blink cursor line after big motions
 | 
					 | 
				
			||||||
       ;;neotree           ; a project drawer, like NERDTree for vim
 | 
					 | 
				
			||||||
       ophints           ; highlight the region an operation acts on
 | 
					 | 
				
			||||||
       (popup +defaults)   ; tame sudden yet inevitable temporary windows
 | 
					 | 
				
			||||||
       tabs              ; a tab bar for Emacs
 | 
					 | 
				
			||||||
       treemacs          ; a project drawer, like neotree but cooler
 | 
					 | 
				
			||||||
       unicode           ; extended unicode support for various languages
 | 
					 | 
				
			||||||
       (vc-gutter +pretty) ; vcs diff in the fringe
 | 
					 | 
				
			||||||
       vi-tilde-fringe   ; fringe tildes to mark beyond EOB
 | 
					 | 
				
			||||||
       ;;window-select     ; visually switch windows
 | 
					 | 
				
			||||||
       workspaces        ; tab emulation, persistence & separate workspaces
 | 
					 | 
				
			||||||
       ;;zen               ; distraction-free coding or writing
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :editor
 | 
					 | 
				
			||||||
       (evil +everywhere); come to the dark side, we have cookies
 | 
					 | 
				
			||||||
       file-templates    ; auto-snippets for empty files
 | 
					 | 
				
			||||||
       fold              ; (nigh) universal code folding
 | 
					 | 
				
			||||||
       ;;(format +onsave)  ; automated prettiness
 | 
					 | 
				
			||||||
       ;;god               ; run Emacs commands without modifier keys
 | 
					 | 
				
			||||||
       ;;lispy             ; vim for lisp, for people who don't like vim
 | 
					 | 
				
			||||||
       ;;multiple-cursors  ; editing in many places at once
 | 
					 | 
				
			||||||
       ;;objed             ; text object editing for the innocent
 | 
					 | 
				
			||||||
       ;;parinfer          ; turn lisp into python, sort of
 | 
					 | 
				
			||||||
       ;;rotate-text       ; cycle region at point between text candidates
 | 
					 | 
				
			||||||
       snippets          ; my elves. They type so I don't have to
 | 
					 | 
				
			||||||
       ;;word-wrap         ; soft wrapping with language-aware indent
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :emacs
 | 
					 | 
				
			||||||
       dired             ; making dired pretty [functional]
 | 
					 | 
				
			||||||
       electric          ; smarter, keyword-based electric-indent
 | 
					 | 
				
			||||||
       ;;ibuffer         ; interactive buffer management
 | 
					 | 
				
			||||||
       undo              ; persistent, smarter undo for your inevitable mistakes
 | 
					 | 
				
			||||||
       vc                ; version-control and Emacs, sitting in a tree
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :term
 | 
					 | 
				
			||||||
       ;;eshell            ; the elisp shell that works everywhere
 | 
					 | 
				
			||||||
       ;;shell             ; simple shell REPL for Emacs
 | 
					 | 
				
			||||||
       ;;term              ; basic terminal emulator for Emacs
 | 
					 | 
				
			||||||
       vterm             ; the best terminal emulation in Emacs
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :checkers
 | 
					 | 
				
			||||||
       syntax              ; tasing you for every semicolon you forget
 | 
					 | 
				
			||||||
       ;;(spell +flyspell) ; tasing you for misspelling mispelling
 | 
					 | 
				
			||||||
       ;;grammar           ; tasing grammar mistake every you make
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :tools
 | 
					 | 
				
			||||||
       ;;ansible
 | 
					 | 
				
			||||||
       ;;biblio            ; Writes a PhD for you (citation needed)
 | 
					 | 
				
			||||||
       debugger          ; FIXME stepping through code, to help you add bugs
 | 
					 | 
				
			||||||
       direnv
 | 
					 | 
				
			||||||
       ;;docker
 | 
					 | 
				
			||||||
       ;;editorconfig      ; let someone else argue about tabs vs spaces
 | 
					 | 
				
			||||||
       ;;ein               ; tame Jupyter notebooks with emacs
 | 
					 | 
				
			||||||
       (eval +overlay)     ; run code, run (also, repls)
 | 
					 | 
				
			||||||
       ;;gist              ; interacting with github gists
 | 
					 | 
				
			||||||
       lookup              ; navigate your code and its documentation
 | 
					 | 
				
			||||||
       ;;lsp               ; M-x vscode
 | 
					 | 
				
			||||||
       magit             ; a git porcelain for Emacs
 | 
					 | 
				
			||||||
       ;;make              ; run make tasks from Emacs
 | 
					 | 
				
			||||||
       ;;pass              ; password manager for nerds
 | 
					 | 
				
			||||||
       ;;pdf               ; pdf enhancements
 | 
					 | 
				
			||||||
       ;;prodigy           ; FIXME managing external services & code builders
 | 
					 | 
				
			||||||
       ;;rgb               ; creating color strings
 | 
					 | 
				
			||||||
       ;;taskrunner        ; taskrunner for all your projects
 | 
					 | 
				
			||||||
       ;;terraform         ; infrastructure as code
 | 
					 | 
				
			||||||
       ;;tmux              ; an API for interacting with tmux
 | 
					 | 
				
			||||||
       ;;tree-sitter       ; syntax and parsing, sitting in a tree...
 | 
					 | 
				
			||||||
       ;;upload            ; map local to remote projects via ssh/ftp
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :os
 | 
					 | 
				
			||||||
       (:if IS-MAC macos)  ; improve compatibility with macOS
 | 
					 | 
				
			||||||
       ;;tty               ; improve the terminal Emacs experience
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :lang
 | 
					 | 
				
			||||||
       ;;agda              ; types of types of types of types...
 | 
					 | 
				
			||||||
       ;;beancount         ; mind the GAAP
 | 
					 | 
				
			||||||
       (cc +lsp)         ; C > C++ == 1
 | 
					 | 
				
			||||||
       ;;clojure           ; java with a lisp
 | 
					 | 
				
			||||||
       ;;common-lisp       ; if you've seen one lisp, you've seen them all
 | 
					 | 
				
			||||||
       ;;coq               ; proofs-as-programs
 | 
					 | 
				
			||||||
       ;;crystal           ; ruby at the speed of c
 | 
					 | 
				
			||||||
       ;;csharp            ; unity, .NET, and mono shenanigans
 | 
					 | 
				
			||||||
       ;;data              ; config/data formats
 | 
					 | 
				
			||||||
       ;;(dart +flutter)   ; paint ui and not much else
 | 
					 | 
				
			||||||
       ;;dhall
 | 
					 | 
				
			||||||
       ;;elixir            ; erlang done right
 | 
					 | 
				
			||||||
       ;;elm               ; care for a cup of TEA?
 | 
					 | 
				
			||||||
       emacs-lisp        ; drown in parentheses
 | 
					 | 
				
			||||||
       ;;erlang            ; an elegant language for a more civilized age
 | 
					 | 
				
			||||||
       ;;ess               ; emacs speaks statistics
 | 
					 | 
				
			||||||
       ;;factor
 | 
					 | 
				
			||||||
       ;;faust             ; dsp, but you get to keep your soul
 | 
					 | 
				
			||||||
       ;;fortran           ; in FORTRAN, GOD is REAL (unless declared INTEGER)
 | 
					 | 
				
			||||||
       ;;fsharp            ; ML stands for Microsoft's Language
 | 
					 | 
				
			||||||
       ;;fstar             ; (dependent) types and (monadic) effects and Z3
 | 
					 | 
				
			||||||
       ;;gdscript          ; the language you waited for
 | 
					 | 
				
			||||||
       ;;(go +lsp)         ; the hipster dialect
 | 
					 | 
				
			||||||
       ;;(graphql +lsp)    ; Give queries a REST
 | 
					 | 
				
			||||||
       ;;(haskell +lsp)    ; a language that's lazier than I am
 | 
					 | 
				
			||||||
       ;;hy                ; readability of scheme w/ speed of python
 | 
					 | 
				
			||||||
       ;;idris             ; a language you can depend on
 | 
					 | 
				
			||||||
       ;;json              ; At least it ain't XML
 | 
					 | 
				
			||||||
       ;;(java +lsp)       ; the poster child for carpal tunnel syndrome
 | 
					 | 
				
			||||||
       ;;javascript        ; all(hope(abandon(ye(who(enter(here))))))
 | 
					 | 
				
			||||||
       ;;julia             ; a better, faster MATLAB
 | 
					 | 
				
			||||||
       ;;kotlin            ; a better, slicker Java(Script)
 | 
					 | 
				
			||||||
       ;;latex             ; writing papers in Emacs has never been so fun
 | 
					 | 
				
			||||||
       ;;lean              ; for folks with too much to prove
 | 
					 | 
				
			||||||
       ;;ledger            ; be audit you can be
 | 
					 | 
				
			||||||
       ;;lua               ; one-based indices? one-based indices
 | 
					 | 
				
			||||||
       markdown          ; writing docs for people to ignore
 | 
					 | 
				
			||||||
       ;;nim               ; python + lisp at the speed of c
 | 
					 | 
				
			||||||
       nix               ; I hereby declare "nix geht mehr!"
 | 
					 | 
				
			||||||
       ;;ocaml             ; an objective camel
 | 
					 | 
				
			||||||
       org               ; organize your plain life in plain text
 | 
					 | 
				
			||||||
       ;;php               ; perl's insecure younger brother
 | 
					 | 
				
			||||||
       ;;plantuml          ; diagrams for confusing people more
 | 
					 | 
				
			||||||
       ;;purescript        ; javascript, but functional
 | 
					 | 
				
			||||||
       ;;python            ; beautiful is better than ugly
 | 
					 | 
				
			||||||
       ;;qt                ; the 'cutest' gui framework ever
 | 
					 | 
				
			||||||
       ;;racket            ; a DSL for DSLs
 | 
					 | 
				
			||||||
       ;;raku              ; the artist formerly known as perl6
 | 
					 | 
				
			||||||
       ;;rest              ; Emacs as a REST client
 | 
					 | 
				
			||||||
       ;;rst               ; ReST in peace
 | 
					 | 
				
			||||||
       ;;(ruby +rails)     ; 1.step {|i| p "Ruby is #{i.even? ? 'love' : 'life'}"}
 | 
					 | 
				
			||||||
       ;;(rust +lsp)       ; Fe2O3.unwrap().unwrap().unwrap().unwrap()
 | 
					 | 
				
			||||||
       ;;scala             ; java, but good
 | 
					 | 
				
			||||||
       ;;(scheme +guile)   ; a fully conniving family of lisps
 | 
					 | 
				
			||||||
       sh                ; she sells {ba,z,fi}sh shells on the C xor
 | 
					 | 
				
			||||||
       ;;sml
 | 
					 | 
				
			||||||
       ;;solidity          ; do you need a blockchain? No.
 | 
					 | 
				
			||||||
       ;;swift             ; who asked for emoji variables?
 | 
					 | 
				
			||||||
       ;;terra             ; Earth and Moon in alignment for performance.
 | 
					 | 
				
			||||||
       ;;web               ; the tubes
 | 
					 | 
				
			||||||
       ;;yaml              ; JSON, but readable
 | 
					 | 
				
			||||||
       ;;zig               ; C, but simpler
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :email
 | 
					 | 
				
			||||||
       ;;(mu4e +org +gmail)
 | 
					 | 
				
			||||||
       ;;notmuch
 | 
					 | 
				
			||||||
       ;;(wanderlust +gmail)
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :app
 | 
					 | 
				
			||||||
       ;;calendar
 | 
					 | 
				
			||||||
       ;;emms
 | 
					 | 
				
			||||||
       ;;everywhere        ; *leave* Emacs!? You must be joking
 | 
					 | 
				
			||||||
       ;;irc               ; how neckbeards socialize
 | 
					 | 
				
			||||||
       ;;(rss +org)        ; emacs as an RSS reader
 | 
					 | 
				
			||||||
       ;;twitter           ; twitter client https://twitter.com/vnought
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
       :config
 | 
					 | 
				
			||||||
       ;;literate
 | 
					 | 
				
			||||||
       (default +bindings +smartparens))
 | 
					 | 
				
			||||||
@ -1,50 +0,0 @@
 | 
				
			|||||||
;; -*- no-byte-compile: t; -*-
 | 
					 | 
				
			||||||
;;; $DOOMDIR/packages.el
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; To install a package with Doom you must declare them here and run 'doom sync'
 | 
					 | 
				
			||||||
;; on the command line, then restart Emacs for the changes to take effect -- or
 | 
					 | 
				
			||||||
;; use 'M-x doom/reload'.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; To install SOME-PACKAGE from MELPA, ELPA or emacsmirror:
 | 
					 | 
				
			||||||
;(package! some-package)
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; To install a package directly from a remote git repo, you must specify a
 | 
					 | 
				
			||||||
;; `:recipe'. You'll find documentation on what `:recipe' accepts here:
 | 
					 | 
				
			||||||
;; https://github.com/radian-software/straight.el#the-recipe-format
 | 
					 | 
				
			||||||
;(package! another-package
 | 
					 | 
				
			||||||
;  :recipe (:host github :repo "username/repo"))
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; If the package you are trying to install does not contain a PACKAGENAME.el
 | 
					 | 
				
			||||||
;; file, or is located in a subdirectory of the repo, you'll need to specify
 | 
					 | 
				
			||||||
;; `:files' in the `:recipe':
 | 
					 | 
				
			||||||
;(package! this-package
 | 
					 | 
				
			||||||
;  :recipe (:host github :repo "username/repo"
 | 
					 | 
				
			||||||
;           :files ("some-file.el" "src/lisp/*.el")))
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; If you'd like to disable a package included with Doom, you can do so here
 | 
					 | 
				
			||||||
;; with the `:disable' property:
 | 
					 | 
				
			||||||
;(package! builtin-package :disable t)
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; You can override the recipe of a built in package without having to specify
 | 
					 | 
				
			||||||
;; all the properties for `:recipe'. These will inherit the rest of its recipe
 | 
					 | 
				
			||||||
;; from Doom or MELPA/ELPA/Emacsmirror:
 | 
					 | 
				
			||||||
;(package! builtin-package :recipe (:nonrecursive t))
 | 
					 | 
				
			||||||
;(package! builtin-package-2 :recipe (:repo "myfork/package"))
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; Specify a `:branch' to install a package from a particular branch or tag.
 | 
					 | 
				
			||||||
;; This is required for some packages whose default branch isn't 'master' (which
 | 
					 | 
				
			||||||
;; our package manager can't deal with; see radian-software/straight.el#279)
 | 
					 | 
				
			||||||
;(package! builtin-package :recipe (:branch "develop"))
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; Use `:pin' to specify a particular commit to install.
 | 
					 | 
				
			||||||
;(package! builtin-package :pin "1a2b3c4d5e")
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
;; Doom's packages are pinned to a specific commit and updated from release to
 | 
					 | 
				
			||||||
;; release. The `unpin!' macro allows you to unpin single packages...
 | 
					 | 
				
			||||||
;(unpin! pinned-package)
 | 
					 | 
				
			||||||
;; ...or multiple packages
 | 
					 | 
				
			||||||
;(unpin! pinned-package another-pinned-package)
 | 
					 | 
				
			||||||
;; ...Or *all* packages (NOT RECOMMENDED; will likely break things)
 | 
					 | 
				
			||||||
;(unpin! t)
 | 
					 | 
				
			||||||
							
								
								
									
										1638
									
								
								extraFiles/config/zsh/p10kcfg/compatibility.zsh
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1638
									
								
								extraFiles/config/zsh/p10kcfg/compatibility.zsh
									
									
									
									
										vendored
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							
							
								
								
									
										1747
									
								
								extraFiles/config/zsh/p10kcfg/fullcolor.zsh
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1747
									
								
								extraFiles/config/zsh/p10kcfg/fullcolor.zsh
									
									
									
									
										vendored
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							@ -1,45 +0,0 @@
 | 
				
			|||||||
# Stolen from ArchWiki
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# create a zkbd compatible hash;
 | 
					 | 
				
			||||||
# to add other keys to this hash, see: man 5 terminfo
 | 
					 | 
				
			||||||
typeset -A key
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
key[Home]=${terminfo[khome]}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
key[End]=${terminfo[kend]}
 | 
					 | 
				
			||||||
key[Insert]=${terminfo[kich1]}
 | 
					 | 
				
			||||||
key[Delete]=${terminfo[kdch1]}
 | 
					 | 
				
			||||||
key[Up]=${terminfo[kcuu1]}
 | 
					 | 
				
			||||||
key[Down]=${terminfo[kcud1]}
 | 
					 | 
				
			||||||
key[Left]=${terminfo[kcub1]}
 | 
					 | 
				
			||||||
key[Right]=${terminfo[kcuf1]}
 | 
					 | 
				
			||||||
key[PageUp]=${terminfo[kpp]}
 | 
					 | 
				
			||||||
key[PageDown]=${terminfo[knp]}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# setup key accordingly
 | 
					 | 
				
			||||||
[[ -n "${key[Home]}"     ]]  && bindkey  "${key[Home]}"     beginning-of-line
 | 
					 | 
				
			||||||
[[ -n "${key[End]}"      ]]  && bindkey  "${key[End]}"      end-of-line
 | 
					 | 
				
			||||||
[[ -n "${key[Insert]}"   ]]  && bindkey  "${key[Insert]}"   overwrite-mode
 | 
					 | 
				
			||||||
[[ -n "${key[Delete]}"   ]]  && bindkey  "${key[Delete]}"   delete-char
 | 
					 | 
				
			||||||
[[ -n "${key[Up]}"       ]]  && bindkey  "${key[Up]}"       up-line-or-history
 | 
					 | 
				
			||||||
[[ -n "${key[Down]}"     ]]  && bindkey  "${key[Down]}"     down-line-or-history
 | 
					 | 
				
			||||||
[[ -n "${key[Left]}"     ]]  && bindkey  "${key[Left]}"     backward-char
 | 
					 | 
				
			||||||
[[ -n "${key[Right]}"    ]]  && bindkey  "${key[Right]}"    forward-char
 | 
					 | 
				
			||||||
[[ -n "${key[PageUp]}"   ]]  && bindkey  "${key[PageUp]}"   beginning-of-buffer-or-history
 | 
					 | 
				
			||||||
[[ -n "${key[PageDown]}" ]]  && bindkey  "${key[PageDown]}" end-of-buffer-or-history
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# Finally, make sure the terminal is in application mode, when zle is
 | 
					 | 
				
			||||||
# active. Only then are the values from $terminfo valid.
 | 
					 | 
				
			||||||
if (( ${+terminfo[smkx]} )) && (( ${+terminfo[rmkx]} )); then
 | 
					 | 
				
			||||||
    function zle-line-init () {
 | 
					 | 
				
			||||||
        printf '%s' "${terminfo[smkx]}"
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
    function zle-line-finish () {
 | 
					 | 
				
			||||||
        printf '%s' "${terminfo[rmkx]}"
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
    zle -N zle-line-init
 | 
					 | 
				
			||||||
    zle -N zle-line-finish
 | 
					 | 
				
			||||||
fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
@ -1,190 +0,0 @@
 | 
				
			|||||||
#Stolen from grml zsh config 
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
function __zsh_compl () {
 | 
					 | 
				
			||||||
    # TODO: This could use some additional information
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Make sure the completion system is initialised
 | 
					 | 
				
			||||||
    (( ${+_comps} )) || return 1
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # allow one error for every three characters typed in approximate completer
 | 
					 | 
				
			||||||
    zstyle ':completion:*:approximate:'    max-errors 'reply=( $((($#PREFIX+$#SUFFIX)/3 )) numeric )'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # don't complete backup files as executables
 | 
					 | 
				
			||||||
    zstyle ':completion:*:complete:-command-::commands' ignored-patterns '(aptitude-*|*\~)'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # start menu completion only if it could find no unambiguous initial string
 | 
					 | 
				
			||||||
    zstyle ':completion:*:correct:*'       insert-unambiguous true
 | 
					 | 
				
			||||||
    zstyle ':completion:*:corrections'     format $'%{\e[0;31m%}%d (errors: %e)%{\e[0m%}'
 | 
					 | 
				
			||||||
    zstyle ':completion:*:correct:*'       original true
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # activate color-completion
 | 
					 | 
				
			||||||
    zstyle ':completion:*:default'         list-colors ${(s.:.)LS_COLORS}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # format on completion
 | 
					 | 
				
			||||||
    zstyle ':completion:*:descriptions'    format $'%{\e[0;31m%}completing %B%d%b%{\e[0m%}'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # automatically complete 'cd -<tab>' and 'cd -<ctrl-d>' with menu
 | 
					 | 
				
			||||||
    # zstyle ':completion:*:*:cd:*:directory-stack' menu yes select
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # insert all expansions for expand completer
 | 
					 | 
				
			||||||
    zstyle ':completion:*:expand:*'        tag-order all-expansions
 | 
					 | 
				
			||||||
    zstyle ':completion:*:history-words'   list false
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # activate menu
 | 
					 | 
				
			||||||
    zstyle ':completion:*:history-words'   menu yes
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # ignore duplicate entries
 | 
					 | 
				
			||||||
    zstyle ':completion:*:history-words'   remove-all-dups yes
 | 
					 | 
				
			||||||
    zstyle ':completion:*:history-words'   stop yes
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # match uppercase from lowercase
 | 
					 | 
				
			||||||
    zstyle ':completion:*'                 matcher-list 'm:{a-z}={A-Z}'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # separate matches into groups
 | 
					 | 
				
			||||||
    zstyle ':completion:*:matches'         group 'yes'
 | 
					 | 
				
			||||||
    zstyle ':completion:*'                 group-name ''
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    if [[ "$NOMENU" -eq 0 ]] ; then
 | 
					 | 
				
			||||||
        # if there are more than 5 options allow selecting from a menu
 | 
					 | 
				
			||||||
        zstyle ':completion:*'               menu select=5
 | 
					 | 
				
			||||||
    else
 | 
					 | 
				
			||||||
        # don't use any menus at all
 | 
					 | 
				
			||||||
        setopt no_auto_menu
 | 
					 | 
				
			||||||
    fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    zstyle ':completion:*:messages'        format '%d'
 | 
					 | 
				
			||||||
    zstyle ':completion:*:options'         auto-description '%d'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # describe options in full
 | 
					 | 
				
			||||||
    zstyle ':completion:*:options'         description 'yes'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # on processes completion complete all user processes
 | 
					 | 
				
			||||||
    zstyle ':completion:*:processes'       command 'ps -au$USER'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # offer indexes before parameters in subscripts
 | 
					 | 
				
			||||||
    zstyle ':completion:*:*:-subscript-:*' tag-order indexes parameters
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # provide verbose completion information
 | 
					 | 
				
			||||||
    zstyle ':completion:*'                 verbose true
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # recent (as of Dec 2007) zsh versions are able to provide descriptions
 | 
					 | 
				
			||||||
    # for commands (read: 1st word in the line) that it will list for the user
 | 
					 | 
				
			||||||
    # to choose from. The following disables that, because it's not exactly fast.
 | 
					 | 
				
			||||||
    zstyle ':completion:*:-command-:*:'    verbose false
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # set format for warnings
 | 
					 | 
				
			||||||
    zstyle ':completion:*:warnings'        format $'%{\e[0;31m%}No matches for:%{\e[0m%} %d'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # define files to ignore for zcompile
 | 
					 | 
				
			||||||
    zstyle ':completion:*:*:zcompile:*'    ignored-patterns '(*~|*.zwc)'
 | 
					 | 
				
			||||||
    zstyle ':completion:correct:'          prompt 'correct to: %e'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Ignore completion functions for commands you don't have:
 | 
					 | 
				
			||||||
    zstyle ':completion::(^approximate*):*:functions' ignored-patterns '_*'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Provide more processes in completion of programs like killall:
 | 
					 | 
				
			||||||
    zstyle ':completion:*:processes-names' command 'ps c -u ${USER} -o command | uniq'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # complete manual by their section
 | 
					 | 
				
			||||||
    zstyle ':completion:*:manuals'    separate-sections true
 | 
					 | 
				
			||||||
    zstyle ':completion:*:manuals.*'  insert-sections   true
 | 
					 | 
				
			||||||
    zstyle ':completion:*:man:*'      menu yes select
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Search path for sudo completion
 | 
					 | 
				
			||||||
    zstyle ':completion:*:sudo:*' command-path /usr/local/sbin \
 | 
					 | 
				
			||||||
                                               /usr/local/bin  \
 | 
					 | 
				
			||||||
                                               /usr/sbin       \
 | 
					 | 
				
			||||||
                                               /usr/bin        \
 | 
					 | 
				
			||||||
                                               /sbin           \
 | 
					 | 
				
			||||||
                                               /bin            \
 | 
					 | 
				
			||||||
                                               /usr/X11R6/bin  \
 | 
					 | 
				
			||||||
                                               /run/current-system/sw/bin   \
 | 
					 | 
				
			||||||
                                               /run/current-system/sw/sbin
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # provide .. as a completion
 | 
					 | 
				
			||||||
    zstyle ':completion:*' special-dirs ..
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # run rehash on completion so new installed program are found automatically:
 | 
					 | 
				
			||||||
    function _force_rehash () {
 | 
					 | 
				
			||||||
        (( CURRENT == 1 )) && rehash
 | 
					 | 
				
			||||||
        return 1
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    ## correction
 | 
					 | 
				
			||||||
    # some people don't like the automatic correction - so run 'NOCOR=1 zsh' to deactivate it
 | 
					 | 
				
			||||||
    if [[ "$NOCOR" -gt 0 ]] ; then
 | 
					 | 
				
			||||||
        zstyle ':completion:*' completer _oldlist _expand _force_rehash _complete _files _ignored
 | 
					 | 
				
			||||||
        setopt nocorrect
 | 
					 | 
				
			||||||
    else
 | 
					 | 
				
			||||||
        # try to be smart about when to use what completer...
 | 
					 | 
				
			||||||
        setopt correct
 | 
					 | 
				
			||||||
        zstyle -e ':completion:*' completer '
 | 
					 | 
				
			||||||
            if [[ $_last_try != "$HISTNO$BUFFER$CURSOR" ]] ; then
 | 
					 | 
				
			||||||
                _last_try="$HISTNO$BUFFER$CURSOR"
 | 
					 | 
				
			||||||
                reply=(_complete _match _ignored _prefix _files)
 | 
					 | 
				
			||||||
            else
 | 
					 | 
				
			||||||
                if [[ $words[1] == (rm|mv) ]] ; then
 | 
					 | 
				
			||||||
                    reply=(_complete _files)
 | 
					 | 
				
			||||||
                else
 | 
					 | 
				
			||||||
                    reply=(_oldlist _expand _force_rehash _complete _ignored _correct _approximate _files)
 | 
					 | 
				
			||||||
                fi
 | 
					 | 
				
			||||||
            fi'
 | 
					 | 
				
			||||||
    fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # command for process lists, the local web server details and host completion
 | 
					 | 
				
			||||||
    zstyle ':completion:*:urls' local 'www' '/var/www/' 'public_html'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Some functions, like _apt and _dpkg, are very slow. We can use a cache in
 | 
					 | 
				
			||||||
    # order to speed things up
 | 
					 | 
				
			||||||
    if [[ ${__COMP_CACHING:-yes} == yes ]]; then
 | 
					 | 
				
			||||||
        __COMP_CACHE_DIR=${__COMP_CACHE_DIR:-${ZDOTDIR:-$HOME}/.cache}
 | 
					 | 
				
			||||||
        if [[ ! -d ${__COMP_CACHE_DIR} ]]; then
 | 
					 | 
				
			||||||
            command mkdir -p "${__COMP_CACHE_DIR}"
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
        zstyle ':completion:*' use-cache  yes
 | 
					 | 
				
			||||||
        zstyle ':completion:*:complete:*' cache-path "${__COMP_CACHE_DIR}"
 | 
					 | 
				
			||||||
    fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # host completion
 | 
					 | 
				
			||||||
    _etc_hosts=()
 | 
					 | 
				
			||||||
    _ssh_config_hosts=()
 | 
					 | 
				
			||||||
    _ssh_hosts=()
 | 
					 | 
				
			||||||
        if [[ -r ~/.ssh/config ]] ; then
 | 
					 | 
				
			||||||
            _ssh_config_hosts=(${${(s: :)${(ps:\t:)${${(@M)${(f)"$(<$HOME/.ssh/config)"}:#Host *}#Host }}}:#*[*?]*})
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        if [[ -r ~/.ssh/known_hosts ]] ; then
 | 
					 | 
				
			||||||
            _ssh_hosts=(${${${${(f)"$(<$HOME/.ssh/known_hosts)"}:#[\|]*}%%\ *}%%,*})
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        if [[ -r /etc/hosts ]] && [[ "$NOETCHOSTS" -eq 0 ]] ; then
 | 
					 | 
				
			||||||
            : ${(A)_etc_hosts:=${(s: :)${(ps:\t:)${${(f)~~"$(grep -v '^0\.0\.0\.0\|^127\.0\.0\.1\|^::1 ' /etc/hosts)"}%%\#*}##[:blank:]#[^[:blank:]]#}}}
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    local localname
 | 
					 | 
				
			||||||
    localname="$(uname -n)"
 | 
					 | 
				
			||||||
    hosts=(
 | 
					 | 
				
			||||||
        "${localname}"
 | 
					 | 
				
			||||||
        "$_ssh_config_hosts[@]"
 | 
					 | 
				
			||||||
        "$_ssh_hosts[@]"
 | 
					 | 
				
			||||||
        "$_etc_hosts[@]"
 | 
					 | 
				
			||||||
        localhost
 | 
					 | 
				
			||||||
    )
 | 
					 | 
				
			||||||
    zstyle ':completion:*:hosts' hosts $hosts
 | 
					 | 
				
			||||||
    # TODO: so, why is this here?
 | 
					 | 
				
			||||||
    #  zstyle '*' hosts $hosts
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # use generic completion system for programs not yet defined; (_gnu_generic works
 | 
					 | 
				
			||||||
    # with commands that provide a --help option with "standard" gnu-like output.)
 | 
					 | 
				
			||||||
    for compcom in cp deborphan df feh fetchipac gpasswd head hnb ipacsum mv \
 | 
					 | 
				
			||||||
                   pal stow uname ; do
 | 
					 | 
				
			||||||
        [[ -z ${_comps[$compcom]} ]] && compdef _gnu_generic ${compcom}
 | 
					 | 
				
			||||||
    done; unset compcom
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # see upgrade function in this file
 | 
					 | 
				
			||||||
    compdef _hosts upgrade
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
__zsh_compl
 | 
					 | 
				
			||||||
@ -1 +0,0 @@
 | 
				
			|||||||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPEDY+H8Hc/RSLE064AAh8IojvqxPd8BE5gec2aOfYMh materus@podkos.pl
 | 
					 | 
				
			||||||
							
								
								
									
										55
									
								
								flake.lock
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										55
									
								
								flake.lock
									
									
									
										generated
									
									
									
								
							@ -9,11 +9,11 @@
 | 
				
			|||||||
        "nixpkgs-stable": "nixpkgs-stable"
 | 
					        "nixpkgs-stable": "nixpkgs-stable"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "locked": {
 | 
					      "locked": {
 | 
				
			||||||
        "lastModified": 1696357822,
 | 
					        "lastModified": 1696730756,
 | 
				
			||||||
        "narHash": "sha256-wAXP7mk5zJ2sIW9cH1Oxf/f1AY3jtAgLFwvQMvJ9o4s=",
 | 
					        "narHash": "sha256-u+UbAnVCD3RnMyXgvo5k0fDmyRNAixDh07lrOSdtZgs=",
 | 
				
			||||||
        "owner": "nix-community",
 | 
					        "owner": "nix-community",
 | 
				
			||||||
        "repo": "emacs-overlay",
 | 
					        "repo": "emacs-overlay",
 | 
				
			||||||
        "rev": "d88c1d26a6874ab9ef657753e170bbcee7506ce1",
 | 
					        "rev": "3f942773192735d987ab517ceaae2a0479d4e601",
 | 
				
			||||||
        "type": "github"
 | 
					        "type": "github"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "original": {
 | 
					      "original": {
 | 
				
			||||||
@ -48,11 +48,11 @@
 | 
				
			|||||||
        ]
 | 
					        ]
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "locked": {
 | 
					      "locked": {
 | 
				
			||||||
        "lastModified": 1696349083,
 | 
					        "lastModified": 1696737557,
 | 
				
			||||||
        "narHash": "sha256-hs7GLezeY40EQpZSYYhfgcKhAogF3MBYKWZ1o+Bxrog=",
 | 
					        "narHash": "sha256-YD/pjDjj/BNmisEvRdM/vspkCU3xyyeGVAUWhvVSi5Y=",
 | 
				
			||||||
        "owner": "nix-community",
 | 
					        "owner": "nix-community",
 | 
				
			||||||
        "repo": "home-manager",
 | 
					        "repo": "home-manager",
 | 
				
			||||||
        "rev": "55ce64c3ca031eefb1adac85bb0025887ed7a221",
 | 
					        "rev": "3c1d8758ac3f55ab96dcaf4d271c39da4b6e836d",
 | 
				
			||||||
        "type": "github"
 | 
					        "type": "github"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "original": {
 | 
					      "original": {
 | 
				
			||||||
@ -64,11 +64,11 @@
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
    "nixpkgs": {
 | 
					    "nixpkgs": {
 | 
				
			||||||
      "locked": {
 | 
					      "locked": {
 | 
				
			||||||
        "lastModified": 1696019113,
 | 
					        "lastModified": 1696604326,
 | 
				
			||||||
        "narHash": "sha256-X3+DKYWJm93DRSdC5M6K5hLqzSya9BjibtBsuARoPco=",
 | 
					        "narHash": "sha256-YXUNI0kLEcI5g8lqGMb0nh67fY9f2YoJsILafh6zlMo=",
 | 
				
			||||||
        "owner": "NixOS",
 | 
					        "owner": "NixOS",
 | 
				
			||||||
        "repo": "nixpkgs",
 | 
					        "repo": "nixpkgs",
 | 
				
			||||||
        "rev": "f5892ddac112a1e9b3612c39af1b72987ee5783a",
 | 
					        "rev": "87828a0e03d1418e848d3dd3f3014a632e4a4f64",
 | 
				
			||||||
        "type": "github"
 | 
					        "type": "github"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "original": {
 | 
					      "original": {
 | 
				
			||||||
@ -80,11 +80,11 @@
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
    "nixpkgs-stable": {
 | 
					    "nixpkgs-stable": {
 | 
				
			||||||
      "locked": {
 | 
					      "locked": {
 | 
				
			||||||
        "lastModified": 1696039360,
 | 
					        "lastModified": 1696374741,
 | 
				
			||||||
        "narHash": "sha256-g7nIUV4uq1TOVeVIDEZLb005suTWCUjSY0zYOlSBsyE=",
 | 
					        "narHash": "sha256-gt8B3G0ryizT9HSB4cCO8QoxdbsHnrQH+/BdKxOwqF0=",
 | 
				
			||||||
        "owner": "NixOS",
 | 
					        "owner": "NixOS",
 | 
				
			||||||
        "repo": "nixpkgs",
 | 
					        "repo": "nixpkgs",
 | 
				
			||||||
        "rev": "32dcb45f66c0487e92db8303a798ebc548cadedc",
 | 
					        "rev": "8a4c17493e5c39769f79117937c79e1c88de6729",
 | 
				
			||||||
        "type": "github"
 | 
					        "type": "github"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "original": {
 | 
					      "original": {
 | 
				
			||||||
@ -96,34 +96,16 @@
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
    "nur": {
 | 
					    "nur": {
 | 
				
			||||||
      "locked": {
 | 
					      "locked": {
 | 
				
			||||||
        "lastModified": 1696362342,
 | 
					        "lastModified": 1696749357,
 | 
				
			||||||
        "narHash": "sha256-cEWraMnkXlQS1gG/SoAdrYXxN53rrIZ+ZE5DrmiIu00=",
 | 
					        "narHash": "sha256-DOinkqGrYPGqE0cQ6iQfN8Rwhdj43OGmn4U0402PSKk=",
 | 
				
			||||||
        "owner": "nix-community",
 | 
					        "owner": "nix-community",
 | 
				
			||||||
        "repo": "NUR",
 | 
					        "repo": "NUR",
 | 
				
			||||||
        "rev": "c16910a91529fb6ac161feaf427c34e8ab118d8c",
 | 
					        "rev": "f77ed4768c0b2763cae81a30a1905145178c105e",
 | 
				
			||||||
        "type": "github"
 | 
					        "type": "github"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "original": {
 | 
					      "original": {
 | 
				
			||||||
        "owner": "nix-community",
 | 
					        "id": "nur",
 | 
				
			||||||
        "ref": "master",
 | 
					        "type": "indirect"
 | 
				
			||||||
        "repo": "NUR",
 | 
					 | 
				
			||||||
        "type": "github"
 | 
					 | 
				
			||||||
      }
 | 
					 | 
				
			||||||
    },
 | 
					 | 
				
			||||||
    "private": {
 | 
					 | 
				
			||||||
      "locked": {
 | 
					 | 
				
			||||||
        "lastModified": 1684365822,
 | 
					 | 
				
			||||||
        "narHash": "sha256-qly3A3GgIYYwCSYIrmYRI7SJ6Q1I4Mo2zipJOrj50r0=",
 | 
					 | 
				
			||||||
        "owner": "materusPL",
 | 
					 | 
				
			||||||
        "repo": "Nixerus",
 | 
					 | 
				
			||||||
        "rev": "f07f3e99a7cd8680dd6bb082108a67830857e542",
 | 
					 | 
				
			||||||
        "type": "github"
 | 
					 | 
				
			||||||
      },
 | 
					 | 
				
			||||||
      "original": {
 | 
					 | 
				
			||||||
        "owner": "materusPL",
 | 
					 | 
				
			||||||
        "ref": "mock",
 | 
					 | 
				
			||||||
        "repo": "Nixerus",
 | 
					 | 
				
			||||||
        "type": "github"
 | 
					 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    "root": {
 | 
					    "root": {
 | 
				
			||||||
@ -131,8 +113,7 @@
 | 
				
			|||||||
        "emacs-overlay": "emacs-overlay",
 | 
					        "emacs-overlay": "emacs-overlay",
 | 
				
			||||||
        "home-manager": "home-manager",
 | 
					        "home-manager": "home-manager",
 | 
				
			||||||
        "nixpkgs": "nixpkgs",
 | 
					        "nixpkgs": "nixpkgs",
 | 
				
			||||||
        "nur": "nur",
 | 
					        "nur": "nur"
 | 
				
			||||||
        "private": "private"
 | 
					 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    "systems": {
 | 
					    "systems": {
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										23
									
								
								flake.nix
									
									
									
									
									
								
							
							
						
						
									
										23
									
								
								flake.nix
									
									
									
									
									
								
							@ -16,12 +16,6 @@
 | 
				
			|||||||
        nixpkgs.follows = "nixpkgs";
 | 
					        nixpkgs.follows = "nixpkgs";
 | 
				
			||||||
      };
 | 
					      };
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
    nur = {
 | 
					 | 
				
			||||||
      type = "github";
 | 
					 | 
				
			||||||
      owner = "nix-community";
 | 
					 | 
				
			||||||
      repo = "NUR";
 | 
					 | 
				
			||||||
      ref = "master";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
    emacs-overlay = {
 | 
					    emacs-overlay = {
 | 
				
			||||||
      type = "github";
 | 
					      type = "github";
 | 
				
			||||||
      owner = "nix-community";
 | 
					      owner = "nix-community";
 | 
				
			||||||
@ -31,12 +25,11 @@
 | 
				
			|||||||
        nixpkgs.follows = "nixpkgs";
 | 
					        nixpkgs.follows = "nixpkgs";
 | 
				
			||||||
      };
 | 
					      };
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
 | 
					    nur = {
 | 
				
			||||||
    private = {
 | 
					 | 
				
			||||||
      type = "github";
 | 
					      type = "github";
 | 
				
			||||||
      owner = "materusPL";
 | 
					      owner = "nix-community";
 | 
				
			||||||
      repo = "Nixerus";
 | 
					      repo = "NUR";
 | 
				
			||||||
      ref = "mock";
 | 
					      ref = "master";
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -51,15 +44,11 @@
 | 
				
			|||||||
      forAllSystems = f: nixpkgs.lib.genAttrs systems (system: f system);
 | 
					      forAllSystems = f: nixpkgs.lib.genAttrs systems (system: f system);
 | 
				
			||||||
    in
 | 
					    in
 | 
				
			||||||
    rec {
 | 
					    rec {
 | 
				
			||||||
 | 
					      inherit inputs;
 | 
				
			||||||
      packages = forAllSystems (system: import ./default.nix {
 | 
					      packages = forAllSystems (system: import ./default.nix {
 | 
				
			||||||
        pkgs = import nixpkgs { inherit system; };
 | 
					        pkgs = import nixpkgs { inherit system; };
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
 | 
					      selfPath = ./.;
 | 
				
			||||||
      nixosConfigurations = import ./configurations/host { inherit inputs; materusFlake = self; };
 | 
					 | 
				
			||||||
      homeConfigurations = import ./configurations/home { inherit inputs; materusFlake = self; };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      path = ./.;
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user