diff --git a/hosts/sakotop/configuration.nix b/hosts/sakotop/configuration.nix index 1efc57b4..d0970e1b 100644 --- a/hosts/sakotop/configuration.nix +++ b/hosts/sakotop/configuration.nix @@ -1,12 +1,17 @@ # 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, lib, inputs, outputs, ... }: { - imports = - [ # Include the results of the hardware scan. - ./hardware-configuration.nix - ]; + config, + pkgs, + lib, + inputs, + outputs, + ... +}: { + imports = [ + # Include the results of the hardware scan. + ./hardware-configuration.nix + ]; # required for hostname specific configurations networking.hostName = "sakotop"; # Define your hostname. @@ -18,7 +23,7 @@ awesome.enable = false; dwm.enable = true; picom.enable = false; - gnome.enable = false; + gnome.enable = false; dunst.enable = true; browsers = { qutebrowser.enable = true; @@ -72,7 +77,7 @@ # makes nix search nixpkgs # ALOT faster search.enable = true; - # optimize store + # optimize store optimize.enable = true; }; zsh.enable = true; @@ -91,12 +96,12 @@ # TODO(sako):: put this in different files # Define a user account. Don't forget to set a password with ‘passwd’. - users.users.sako= { + users.users.sako = { isNormalUser = true; - extraGroups = [ "wheel" "networkmanager" ]; # Enable ‘sudo’ for the user. + extraGroups = ["wheel" "networkmanager"]; # Enable ‘sudo’ for the user. }; - services.xserver.videoDrivers = [ "nvidia" ]; + services.xserver.videoDrivers = ["nvidia"]; # Enable the OpenSSH daemon. # services.openssh.enable = true; @@ -106,6 +111,4 @@ # networking.firewall.allowedUDPPorts = [ ... ]; # Or disable the firewall altogether. # networking.firewall.enable = false; - } - diff --git a/modules/desktop/bspwm/default.nix b/modules/desktop/bspwm/default.nix index f9912bd9..c042abaf 100644 --- a/modules/desktop/bspwm/default.nix +++ b/modules/desktop/bspwm/default.nix @@ -1,9 +1,14 @@ -{ outputs, options, config, lib, pkgs, ...}: -with lib; -let - cfg = config.modules.desktop.bspwm; -in { + outputs, + options, + config, + lib, + pkgs, + ... +}: +with lib; let + cfg = config.modules.desktop.bspwm; +in { imports = [ ./polybar ./lemonbar @@ -19,19 +24,18 @@ in bspwm.enable = true; }; displayManager = { - defaultSession = "none+bspwm"; - lightdm = { - enable = true; - background = ../../../config/bspwm/background.png; - greeters.gtk = { + defaultSession = "none+bspwm"; + lightdm = { enable = true; - theme = { - name = "vimix-dark-ruby"; - package = pkgs.vimix-gtk-themes; + background = ../../../config/bspwm/background.png; + greeters.gtk = { + enable = true; + theme = { + name = "vimix-dark-ruby"; + package = pkgs.vimix-gtk-themes; + }; }; }; - - }; }; libinput = { enable = true; @@ -46,7 +50,7 @@ in accelProfile = "flat"; }; }; - }; + }; users.users.sako.packages = with pkgs; [ rofi # network @@ -62,9 +66,9 @@ in flameshot ]; - home-manager.users.sako = { pkgs , ...}: { + home-manager.users.sako = {pkgs, ...}: { home.pointerCursor = { - name = "Catppuccin-Mocha-Dark"; + name = "Catppuccin-Mocha-Dark"; size = 16; x11 = { enable = true; @@ -89,7 +93,7 @@ in sxhkd = { source = ../../../config/sxhkd; }; - }; + }; }; }; } diff --git a/modules/desktop/dwm/default.nix b/modules/desktop/dwm/default.nix index 6c893939..668840d1 100644 --- a/modules/desktop/dwm/default.nix +++ b/modules/desktop/dwm/default.nix @@ -1,9 +1,14 @@ -{ outputs, options, config, lib, pkgs, ...}: -with lib; -let - cfg = config.modules.desktop.dwm; -in { + outputs, + options, + config, + lib, + pkgs, + ... +}: +with lib; let + cfg = config.modules.desktop.dwm; +in { options.modules.desktop.dwm = { enable = mkEnableOption false; }; @@ -27,16 +32,16 @@ in }; }; }; - libinput = { - mouse = { - accelProfile = "flat"; - }; + libinput = { + mouse = { + accelProfile = "flat"; + }; - touchpad = { - accelProfile = "flat"; + touchpad = { + accelProfile = "flat"; + }; }; }; - }; users.users.sako.packages = with pkgs; [ rofi # network @@ -51,7 +56,7 @@ in # screen shot (s) flameshot ]; - home-manager.users.sako = { pkgs , ...}: { + home-manager.users.sako = {pkgs, ...}: { home.file = { "background.png" = { enable = true; @@ -64,7 +69,7 @@ in }; }; home.pointerCursor = { - name = "Catppuccin-Mocha-Dark"; + name = "Catppuccin-Mocha-Dark"; size = 16; x11 = { enable = true; diff --git a/modules/desktop/xmonad/default.nix b/modules/desktop/xmonad/default.nix index a2447f19..3be789c4 100644 --- a/modules/desktop/xmonad/default.nix +++ b/modules/desktop/xmonad/default.nix @@ -1,25 +1,30 @@ -{ outputs, options, config, lib, pkgs, ...}: -with lib; -let - cfg = config.modules.desktop.xmonad; -in { + outputs, + options, + config, + lib, + pkgs, + ... +}: +with lib; let + cfg = config.modules.desktop.xmonad; +in { options.modules.desktop.xmonad = { enable = mkEnableOption false; }; config = mkIf cfg.enable { - # https://nixos.wiki/wiki/XMonad + # https://nixos.wiki/wiki/XMonad services.xserver = { enable = true; windowManager.xmonad = { enable = true; enableContribAndExtras = true; - ghcArgs = [ - "-hidir /tmp" # place interface files in /tmp, otherwise ghc tries to write them to the nix store - "-odir /tmp" # place object files in /tmp, otherwise ghc tries to write them to the nix store -# "-i${xmonad-contexts}" # tell ghc to search in the respective nix store path for the module - ]; + ghcArgs = [ + "-hidir /tmp" # place interface files in /tmp, otherwise ghc tries to write them to the nix store + "-odir /tmp" # place object files in /tmp, otherwise ghc tries to write them to the nix store + # "-i${xmonad-contexts}" # tell ghc to search in the respective nix store path for the module + ]; }; displayManager = { lightdm = { @@ -42,7 +47,7 @@ in accelProfile = "flat"; }; - # touchpad + # touchpad touchpad = { accelProfile = "flat"; }; @@ -71,9 +76,9 @@ in trayer ]; - home-manager.users.sako = { pkgs , ...}: { + home-manager.users.sako = {pkgs, ...}: { home.pointerCursor = { - name = "Catppuccin-Mocha-Dark"; + name = "Catppuccin-Mocha-Dark"; size = 16; x11 = { enable = true; @@ -100,7 +105,7 @@ in source = ../../../config/xmobar; recursive = true; }; - }; - }; + }; }; + }; } diff --git a/packages/.nixd.json b/packages/.nixd.json new file mode 100644 index 00000000..dd149e4b --- /dev/null +++ b/packages/.nixd.json @@ -0,0 +1,7 @@ +{ + "eval": { + "target": { + "args": ["--expr", "with import { }; ./default.nix { }"] + } + } +} diff --git a/packages/default.nix b/packages/default.nix index 0a2be808..2aa2711e 100644 --- a/packages/default.nix +++ b/packages/default.nix @@ -1,7 +1,7 @@ # Custom packages, that can be defined similarly to ones from nixpkgs # You can build them using 'nix build .#example' or (legacy) 'nix-build -A example' - -{ pkgs ? (import ../nixpkgs.nix) { } }: { +{pkgs ? (import ../nixpkgs.nix) {}}: { # example = pkgs.callPackage ./example { }; sako.davinci-resolve = pkgs.callPackage ./davinci-resolve.nix {}; + nullpomino = pkgs.callPackage ./nullpomino.nix {}; }