mirror of
https://github.com/starr-dusT/dotfiles.git
synced 2025-05-19 02:46:06 -07:00
add lib folder
This commit is contained in:
parent
d669b7bb9b
commit
3942238dba
@ -14,6 +14,7 @@
|
|||||||
|
|
||||||
# Add non-free packages
|
# Add non-free packages
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
nixpkgs.overlays = import ../../lib/overlays.nix;
|
||||||
|
|
||||||
# Use zen kernel
|
# Use zen kernel
|
||||||
boot.kernelPackages = pkgs.linuxPackages_zen;
|
boot.kernelPackages = pkgs.linuxPackages_zen;
|
||||||
@ -68,10 +69,12 @@
|
|||||||
nerdfonts
|
nerdfonts
|
||||||
];
|
];
|
||||||
|
|
||||||
|
programs.zsh.enable = true;
|
||||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||||
users.users.${user} = {
|
users.users.${user} = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
extraGroups = [ "wheel" "docker" ]; # Enable ‘sudo’ for the user.
|
extraGroups = [ "wheel" "docker" ]; # Enable ‘sudo’ for the user.
|
||||||
|
shell = pkgs.zsh;
|
||||||
};
|
};
|
||||||
|
|
||||||
# List packages installed in system profile. To search, run:
|
# List packages installed in system profile. To search, run:
|
||||||
@ -94,7 +97,6 @@
|
|||||||
gnome-extension-manager
|
gnome-extension-manager
|
||||||
gnome.gnome-tweaks
|
gnome.gnome-tweaks
|
||||||
pinentry-curses
|
pinentry-curses
|
||||||
zsh
|
|
||||||
ripgrep
|
ripgrep
|
||||||
trash-cli
|
trash-cli
|
||||||
];
|
];
|
||||||
@ -125,7 +127,6 @@
|
|||||||
enableSSHSupport = true;
|
enableSSHSupport = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
# Enable modules
|
# Enable modules
|
||||||
imports = [ ../../modules ];
|
imports = [ ../../modules ];
|
||||||
modules = {
|
modules = {
|
||||||
|
@ -14,31 +14,31 @@
|
|||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
fileSystems."/" =
|
fileSystems."/" =
|
||||||
{ device = "/dev/sda2";
|
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = [ "subvol=root" ];
|
options = [ "subvol=root" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/home" =
|
fileSystems."/home" =
|
||||||
{ device = "/dev/sda2";
|
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = [ "subvol=home" ];
|
options = [ "subvol=home" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/nix" =
|
fileSystems."/nix" =
|
||||||
{ device = "/dev/sda2";
|
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = [ "subvol=nix" ];
|
options = [ "subvol=nix" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/persist" =
|
fileSystems."/persist" =
|
||||||
{ device = "/dev/sda2";
|
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = [ "subvol=persist" ];
|
options = [ "subvol=persist" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/var/log" =
|
fileSystems."/var/log" =
|
||||||
{ device = "/dev/sda2";
|
{ device = "/dev/disk/by-uuid/b946d3b5-86ea-4f22-be13-532a60023b98";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = [ "subvol=log" ];
|
options = [ "subvol=log" ];
|
||||||
};
|
};
|
||||||
|
7
provision/nixos/lib/overlays.nix
Normal file
7
provision/nixos/lib/overlays.nix
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
/* This configures nixpkgs.overlays to include our overlays/ directory.
|
||||||
|
*/
|
||||||
|
let path = ../overlays; in with builtins;
|
||||||
|
map (n: import (path + ("/" + n)))
|
||||||
|
(filter (n: match ".*\\.nix" n != null ||
|
||||||
|
pathExists (path + ("/" + n + "/default.nix")))
|
||||||
|
(attrNames (readDir path)))
|
@ -2,23 +2,6 @@
|
|||||||
|
|
||||||
let
|
let
|
||||||
cfg = config.modules.desktop.sway;
|
cfg = config.modules.desktop.sway;
|
||||||
# bash script to let dbus know about important env variables and
|
|
||||||
# propagate them to relevent services run at the end of sway config
|
|
||||||
# see
|
|
||||||
# https://github.com/emersion/xdg-desktop-portal-wlr/wiki/"It-doesn't-work"-Troubleshooting-Checklist
|
|
||||||
# note: this is pretty much the same as /etc/sway/config.d/nixos.conf but also restarts
|
|
||||||
# some user services to make sure they have the correct environment variables
|
|
||||||
dbus-sway-environment = pkgs.writeTextFile {
|
|
||||||
name = "dbus-sway-environment";
|
|
||||||
destination = "/bin/dbus-sway-environment";
|
|
||||||
executable = true;
|
|
||||||
|
|
||||||
text = ''
|
|
||||||
dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway
|
|
||||||
systemctl --user stop pipewire pipewire-media-session xdg-desktop-portal xdg-desktop-portal-wlr
|
|
||||||
systemctl --user start pipewire pipewire-media-session xdg-desktop-portal xdg-desktop-portal-wlr
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
# currently, there is some friction between sway and gtk:
|
# currently, there is some friction between sway and gtk:
|
||||||
# https://github.com/swaywm/sway/wiki/GTK-3-settings-on-Wayland
|
# https://github.com/swaywm/sway/wiki/GTK-3-settings-on-Wayland
|
||||||
@ -46,8 +29,8 @@ in {
|
|||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
sway
|
sway
|
||||||
dbus-sway-environment
|
|
||||||
wayland
|
wayland
|
||||||
|
xwayland
|
||||||
configure-gtk
|
configure-gtk
|
||||||
xdg-utils # for opening default programs when clicking links
|
xdg-utils # for opening default programs when clicking links
|
||||||
glib # gsettings
|
glib # gsettings
|
||||||
@ -59,7 +42,8 @@ in {
|
|||||||
wl-clipboard # wl-copy and wl-paste for copy/paste from stdin / stdout
|
wl-clipboard # wl-copy and wl-paste for copy/paste from stdin / stdout
|
||||||
mako # notification system developed by swaywm maintainer
|
mako # notification system developed by swaywm maintainer
|
||||||
wdisplays # tool to configure displays
|
wdisplays # tool to configure displays
|
||||||
rofi
|
rofip
|
||||||
|
networkmanagerapplet
|
||||||
];
|
];
|
||||||
|
|
||||||
# xdg-desktop-portal works by exposing a series of D-Bus interfaces
|
# xdg-desktop-portal works by exposing a series of D-Bus interfaces
|
||||||
|
@ -4,11 +4,20 @@
|
|||||||
|
|
||||||
let
|
let
|
||||||
cfg = config.modules.devel.python;
|
cfg = config.modules.devel.python;
|
||||||
|
my-python-packages = ps: with ps; [
|
||||||
|
virtualenv
|
||||||
|
i3ipc
|
||||||
|
];
|
||||||
|
|
||||||
in {
|
in {
|
||||||
options.modules.devel.python.enable = lib.mkEnableOption "python";
|
options.modules.devel.python.enable = lib.mkEnableOption "python";
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
|
||||||
# Install packages
|
# Install packages
|
||||||
environment.systemPackages = with pkgs; [ python3 python3Packages.virtualenv beancount fava ];
|
environment.systemPackages = with pkgs; [
|
||||||
|
(python3.withPackages my-python-packages)
|
||||||
|
beancount
|
||||||
|
fava
|
||||||
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -1,5 +0,0 @@
|
|||||||
{ ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
overrides = import ./overrides.nix;
|
|
||||||
}
|
|
@ -1,18 +0,0 @@
|
|||||||
# This overlay is used for overriding upstream packages.
|
|
||||||
|
|
||||||
self: super:
|
|
||||||
|
|
||||||
let
|
|
||||||
nixpkgs-master = import <nixpkgs-master> { inherit (super) config; };
|
|
||||||
nixpkgs-unstable = import <channels-nixos-unstable> { inherit (super) config; };
|
|
||||||
|
|
||||||
in {
|
|
||||||
inherit nixpkgs-master;
|
|
||||||
inherit nixpkgs-unstable;
|
|
||||||
|
|
||||||
qtile = super.qtile.overrideAttrs(oldAttrs: {
|
|
||||||
propagatedBuildInputs = oldAttrs.passthru.unwrapped.propagatedBuildInputs ++ (with self.python3Packages; [
|
|
||||||
pyyaml
|
|
||||||
]);
|
|
||||||
});
|
|
||||||
}
|
|
7
provision/nixos/overlays/rofi.nix
Normal file
7
provision/nixos/overlays/rofi.nix
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
let sources = import ../nix/sources.nix; in
|
||||||
|
self: super: {
|
||||||
|
rofi = pkgs.rofi.override { plugins = [ pkgs.rofi-emoji ]; };
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user