trying
This commit is contained in:
parent
9c47aba177
commit
2b198d1c4d
7 changed files with 298 additions and 44 deletions
|
@ -10,17 +10,16 @@
|
|||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
hardware.openrazer.enable = true;
|
||||
hardware.openrazer.users = [ "emenel" ];
|
||||
hardware.opengl.enable = true;
|
||||
|
||||
# Bootloader.
|
||||
boot.loader.grub.enable = true;
|
||||
boot.loader.grub.device = "/dev/sda";
|
||||
boot.loader.grub.useOSProber = true;
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
boot.kernelPackages = pkgs.linuxPackages_zen;
|
||||
|
||||
networking.hostName = "thegibson"; # 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";
|
||||
networking.hostName = "eddie";
|
||||
|
||||
# Enable networking
|
||||
networking.networkmanager.enable = true;
|
||||
|
@ -32,7 +31,8 @@
|
|||
i18n.defaultLocale = "en_CA.UTF-8";
|
||||
|
||||
nix.nixPath = [ "nixos-config=/home/emenel/source/nixos" ];
|
||||
|
||||
|
||||
nix.package = pkgs.nixFlakes;
|
||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
|
||||
# Enable the X11 windowing system
|
||||
|
@ -84,15 +84,16 @@
|
|||
# enable fish and launch it from bash for interactive shells
|
||||
programs.fish.enable = true;
|
||||
programs.bash = {
|
||||
interactiveShellInit = ''
|
||||
if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]]
|
||||
then
|
||||
shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION=""
|
||||
exec ${pkgs.fish}/bin/fish $LOGIN_OPTION
|
||||
fi
|
||||
'';
|
||||
};
|
||||
interactiveShellInit = ''
|
||||
if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]]
|
||||
then
|
||||
shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION=""
|
||||
exec ${pkgs.fish}/bin/fish $LOGIN_OPTION
|
||||
fi
|
||||
'';
|
||||
};
|
||||
|
||||
services.flatpak.enable = true;
|
||||
|
||||
# Allow unfree packages
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
|
143
dotfile/dot_config/wezterm/wezterm.lua
Normal file
143
dotfile/dot_config/wezterm/wezterm.lua
Normal file
|
@ -0,0 +1,143 @@
|
|||
local wezterm = require 'wezterm'
|
||||
local config = wezterm.config_builder()
|
||||
local act = wezterm.action
|
||||
|
||||
config.default_prog = { '/opt/homebrew/bin/fish', '-l' }
|
||||
|
||||
local bar = wezterm.plugin.require("https://github.com/adriankarlen/bar.wezterm")
|
||||
|
||||
config.font_size = 13
|
||||
config.font = wezterm.font {
|
||||
family = 'JetBrains Mono',
|
||||
weight = 'Medium'
|
||||
}
|
||||
|
||||
config.color_scheme = 'Adventure'
|
||||
|
||||
config.colors = {
|
||||
tab_bar = {
|
||||
inactive_tab = {
|
||||
fg_color = "#444444",
|
||||
bg_color = "#000000"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
config.window_decorations = "RESIZE"
|
||||
|
||||
config.window_padding = {
|
||||
left = 12,
|
||||
right = 12,
|
||||
top = 6,
|
||||
bottom = 6,
|
||||
}
|
||||
|
||||
config.cursor_thickness = 2
|
||||
config.default_cursor_style = 'SteadyBar'
|
||||
|
||||
config.use_fancy_tab_bar = false
|
||||
config.tab_bar_at_bottom = true
|
||||
|
||||
config.enable_kitty_keyboard = true
|
||||
|
||||
config.keys = {
|
||||
{
|
||||
key = ",",
|
||||
mods = "SUPER",
|
||||
action = act.SpawnCommandInNewWindow({
|
||||
cwd = os.getenv("WEZTERM_CONFIG_DIR"),
|
||||
args = { os.getenv("SHELL"), "-c", "$EDITOR $WEZTERM_CONFIG_FILE" },
|
||||
}),
|
||||
},
|
||||
{
|
||||
key = 'Enter',
|
||||
mods = 'SUPER',
|
||||
action = act.SplitVertical { domain = 'CurrentPaneDomain' },
|
||||
},
|
||||
{
|
||||
key = 'Enter',
|
||||
mods = 'SUPER|SHIFT',
|
||||
action = act.SplitHorizontal { domain = 'CurrentPaneDomain' },
|
||||
},
|
||||
{
|
||||
key = 'k',
|
||||
mods = 'SUPER',
|
||||
action = act.Multiple {
|
||||
act.ClearScrollback 'ScrollbackAndViewport',
|
||||
act.SendKey { key = 'L', mods = 'CTRL' },
|
||||
},
|
||||
},
|
||||
{key="LeftArrow", mods="SUPER|META", action=act.ActivateTabRelative(-1)},
|
||||
{key="RightArrow", mods="SUPER|META", action=act.ActivateTabRelative(1)},
|
||||
|
||||
{key="UpArrow", mods="SUPER|META", action=act.ActivatePaneDirection("Prev")},
|
||||
{key="DownArrow", mods="SUPER|META", action=act.ActivatePaneDirection("Next")},
|
||||
|
||||
{ key='h', mods='SUPER|META', action=wezterm.action{ActivatePaneDirection="Left"} },
|
||||
{ key='l', mods='SUPER|META', action=wezterm.action{ActivatePaneDirection="Right"} },
|
||||
{ key='j', mods='SUPER|META', action=wezterm.action{ActivatePaneDirection="Up"} },
|
||||
{ key='k', mods='SUPER|META', action=wezterm.action{ActivatePaneDirection="Down"} },
|
||||
}
|
||||
|
||||
local barconfig = {
|
||||
position = "bottom",
|
||||
max_width = 32,
|
||||
separator = {
|
||||
space = 2,
|
||||
left_icon = wezterm.nerdfonts.fa_long_arrow_right,
|
||||
right_icon = wezterm.nerdfonts.fa_long_arrow_left,
|
||||
field_icon = wezterm.nerdfonts.indent_line,
|
||||
},
|
||||
modules = {
|
||||
tabs = {
|
||||
active_tab_fg = 4,
|
||||
inactive_tab_fg = 8, -- overridden by tab colour customization near the top
|
||||
},
|
||||
workspace = {
|
||||
enabled = true,
|
||||
icon = wezterm.nerdfonts.cod_window,
|
||||
color = 8,
|
||||
},
|
||||
leader = {
|
||||
enabled = true,
|
||||
icon = wezterm.nerdfonts.oct_rocket,
|
||||
color = 2,
|
||||
},
|
||||
pane = {
|
||||
enabled = false,
|
||||
icon = wezterm.nerdfonts.cod_multiple_windows,
|
||||
color = 7,
|
||||
},
|
||||
username = {
|
||||
enabled = true,
|
||||
icon = wezterm.nerdfonts.fa_user,
|
||||
color = 6,
|
||||
},
|
||||
hostname = {
|
||||
enabled = true,
|
||||
icon = wezterm.nerdfonts.cod_server,
|
||||
color = 8,
|
||||
},
|
||||
clock = {
|
||||
enabled = false,
|
||||
icon = wezterm.nerdfonts.md_calendar_clock,
|
||||
color = 5,
|
||||
},
|
||||
cwd = {
|
||||
enabled = true,
|
||||
icon = wezterm.nerdfonts.oct_file_directory,
|
||||
color = 7,
|
||||
},
|
||||
spotify = {
|
||||
enabled = false,
|
||||
icon = wezterm.nerdfonts.fa_spotify,
|
||||
color = 3,
|
||||
max_width = 64,
|
||||
throttle = 15,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
bar.apply_to_config(config, barconfig)
|
||||
|
||||
return config
|
32
flake.lock
generated
32
flake.lock
generated
|
@ -7,32 +7,47 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1719827415,
|
||||
"narHash": "sha256-pvh+1hStXXAZf0sZ1xIJbWGx4u+OGBC1rVx6Wsw0fBw=",
|
||||
"lastModified": 1726989464,
|
||||
"narHash": "sha256-Vl+WVTJwutXkimwGprnEtXc/s/s8sMuXzqXaspIGlwM=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "f2e3c19867262dbe84fdfab42467fc8dd83a2005",
|
||||
"rev": "2f23fa308a7c067e52dfcc30a0758f47043ec176",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"ref": "release-23.11",
|
||||
"ref": "release-24.05",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-flatpak": {
|
||||
"locked": {
|
||||
"lastModified": 1721549352,
|
||||
"narHash": "sha256-nlXJa8RSOX0kykrIYW33ukoHYq+FOSNztHLLgqKwOp8=",
|
||||
"owner": "gmodena",
|
||||
"repo": "nix-flatpak",
|
||||
"rev": "dbce39ea8664820ba9037caaf1e2fad365ed6b4b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "gmodena",
|
||||
"repo": "nix-flatpak",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1720535198,
|
||||
"narHash": "sha256-zwVvxrdIzralnSbcpghA92tWu2DV2lwv89xZc8MTrbg=",
|
||||
"lastModified": 1726969270,
|
||||
"narHash": "sha256-8fnFlXBgM/uSvBlLWjZ0Z0sOdRBesyNdH0+esxqizGc=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "205fd4226592cc83fd4c0885a3e4c9c400efabb5",
|
||||
"rev": "23cbb250f3bf4f516a2d0bf03c51a30900848075",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-23.11",
|
||||
"ref": "nixos-24.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
|
@ -56,6 +71,7 @@
|
|||
"root": {
|
||||
"inputs": {
|
||||
"home-manager": "home-manager",
|
||||
"nix-flatpak": "nix-flatpak",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs-unstable": "nixpkgs-unstable"
|
||||
}
|
||||
|
|
21
flake.nix
21
flake.nix
|
@ -3,19 +3,23 @@
|
|||
description = "My Home Manager configuration";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
|
||||
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
|
||||
home-manager.url = "github:nix-community/home-manager/release-23.11";
|
||||
home-manager.url = "github:nix-community/home-manager/release-24.05";
|
||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
||||
|
||||
nix-flatpak.url = "github:gmodena/nix-flatpak"; # unstable branch. Use github:gmodena/nix-flatpak/?ref=<tag> to pin releases.
|
||||
};
|
||||
|
||||
outputs = inputs@{ nixpkgs, home-manager, ... }: {
|
||||
outputs = inputs@{ nixpkgs, home-manager, nix-flatpak, ... }: {
|
||||
nixosConfigurations = {
|
||||
thegibson = nixpkgs.lib.nixosSystem {
|
||||
eddie = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [ ./configuration.nix ];
|
||||
modules = [
|
||||
nix-flatpak.nixosModules.nix-flatpak
|
||||
./configuration.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -23,7 +27,10 @@
|
|||
homeConfigurations = {
|
||||
"emenel" = home-manager.lib.homeManagerConfiguration {
|
||||
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
||||
modules = [ ./home.nix ];
|
||||
modules = [
|
||||
nix-flatpak.homeManagerModules.nix-flatpak
|
||||
./home.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -8,26 +8,33 @@
|
|||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "thunderbolt" "usbhid" "usb_storage" "sd_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/91f25a2d-0d73-4d51-a798-e6c7bc88abee";
|
||||
{ device = "/dev/disk/by-uuid/f5d53811-b478-4d20-91e0-4504c33848b4";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/E3CE-0A6E";
|
||||
fsType = "vfat";
|
||||
options = [ "fmask=0077" "dmask=0077" ];
|
||||
};
|
||||
|
||||
swapDevices =
|
||||
[ { device = "/dev/disk/by-uuid/f8a9a852-3ccb-4d00-8e2d-db0d68e688b2"; }
|
||||
];
|
||||
|
||||
# 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.enp0s31f6.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp3s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
||||
|
|
55
home.nix
55
home.nix
|
@ -1,7 +1,18 @@
|
|||
{ lib, pkgs, ... }:
|
||||
{ nix-flatpak, lib, pkgs, ... }:
|
||||
{
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
home = {
|
||||
packages = with pkgs; [
|
||||
plexamp
|
||||
audacity
|
||||
supercollider-with-plugins
|
||||
|
||||
python3
|
||||
sbcl
|
||||
nodejs_22
|
||||
|
||||
kanata-with-cmd
|
||||
wezterm
|
||||
eza
|
||||
fish
|
||||
emacs
|
||||
|
@ -11,14 +22,50 @@
|
|||
bat
|
||||
jq
|
||||
starship
|
||||
|
||||
bitwarden-cli
|
||||
bitwarden-desktop
|
||||
tailscale
|
||||
|
||||
gnome.gnome-software
|
||||
polychromatic
|
||||
|
||||
discord
|
||||
slack
|
||||
|
||||
gnomeExtensions.just-perfection
|
||||
gnomeExtensions.dash-to-dock
|
||||
|
||||
];
|
||||
|
||||
username = "emenel";
|
||||
homeDirectory = "/home/emenel";
|
||||
|
||||
stateVersion = "23.11";
|
||||
stateVersion = "24.05";
|
||||
};
|
||||
|
||||
programs = {
|
||||
home-manager.enable = true;
|
||||
direnv = {
|
||||
enable = true;
|
||||
#enableFishIntegration = true; # see note on other shells below
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
fish.enable = true;
|
||||
};
|
||||
|
||||
programs.home-manager.enable = true;
|
||||
programs.fish.enable = true;
|
||||
services.flatpak.enable = true;
|
||||
|
||||
xdg.systemDirs.data = [
|
||||
"/home/emenel/.local/share/applications"
|
||||
"/var/lib/flatpak/exports/share"
|
||||
"/home/emenel/.local/share/flatpak/exports/share"
|
||||
"/home/emenel/.nix-profile/share/applications"
|
||||
];
|
||||
|
||||
services.flatpak.packages = [
|
||||
"io.github.zen_browser.zen"
|
||||
];
|
||||
|
||||
xdg.configFile."wezterm".source = ./dotfiles/dot_config/wezterm/wezterm.lua;
|
||||
}
|
||||
|
|
33
thegibson/hardware-configuration.nix
Normal file
33
thegibson/hardware-configuration.nix
Normal file
|
@ -0,0 +1,33 @@
|
|||
# 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" "usb_storage" "usbhid" "sd_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/91f25a2d-0d73-4d51-a798-e6c7bc88abee";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
|
||||
# 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.enp0s31f6.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue