format
This commit is contained in:
parent
6411787299
commit
254c963998
5 changed files with 122 additions and 104 deletions
48
flake.nix
48
flake.nix
|
|
@ -15,30 +15,38 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { self, nixpkgs, home-manager, nvf, alejandra, ... }@inputs: {
|
outputs = {
|
||||||
|
self,
|
||||||
|
nixpkgs,
|
||||||
|
home-manager,
|
||||||
|
nvf,
|
||||||
|
alejandra,
|
||||||
|
...
|
||||||
|
} @ inputs: {
|
||||||
# use "nixos", or your hostname as the name of the configuration
|
# use "nixos", or your hostname as the name of the configuration
|
||||||
# it's a better practice than "default" shown in the video
|
# it's a better practice than "default" shown in the video
|
||||||
|
|
||||||
packages."x86_64-linux".default =
|
packages."x86_64-linux".default =
|
||||||
(nvf.lib.neovimConfiguration {
|
(nvf.lib.neovimConfiguration {
|
||||||
pkgs = nixpkgs.legacyPackages."x86_64-linux";
|
pkgs = nixpkgs.legacyPackages."x86_64-linux";
|
||||||
modules = [ ./nvf-configuration.nix ];
|
modules = [./nvf-configuration.nix];
|
||||||
}).neovim;
|
})
|
||||||
|
.neovim;
|
||||||
|
|
||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
nixos = nixpkgs.lib.nixosSystem {
|
nixos = nixpkgs.lib.nixosSystem {
|
||||||
specialArgs = {inherit inputs;};
|
specialArgs = {inherit inputs;};
|
||||||
modules = [
|
modules = [
|
||||||
{
|
{
|
||||||
environment.systemPackages = [alejandra.defaultPackage.x86_64-linux];
|
environment.systemPackages = [alejandra.defaultPackage.x86_64-linux];
|
||||||
}
|
}
|
||||||
|
|
||||||
./hosts/hummingbird/configuration.nix
|
./hosts/hummingbird/configuration.nix
|
||||||
inputs.home-manager.nixosModules.default
|
inputs.home-manager.nixosModules.default
|
||||||
nvf.nixosModules.default
|
nvf.nixosModules.default
|
||||||
./nvf-configuration.nix
|
./nvf-configuration.nix
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,29 +1,31 @@
|
||||||
# Edit this configuration file to define what should be installed on
|
# Edit this configuration file to define what should be installed on
|
||||||
# your system. Help is available in the configuration.nix(5) man page
|
# your system. Help is available in the configuration.nix(5) man page
|
||||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||||
|
|
||||||
{ config, lib, pkgs, inputs, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
config,
|
||||||
[ # Include the results of the hardware scan.
|
lib,
|
||||||
./hardware-configuration.nix
|
pkgs,
|
||||||
inputs.home-manager.nixosModules.default
|
inputs,
|
||||||
];
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
# Include the results of the hardware scan.
|
||||||
|
./hardware-configuration.nix
|
||||||
|
inputs.home-manager.nixosModules.default
|
||||||
|
];
|
||||||
|
|
||||||
# Bootloader.
|
# Bootloader.
|
||||||
boot.loader.systemd-boot.enable = true;
|
boot.loader.systemd-boot.enable = true;
|
||||||
boot.loader.efi.canTouchEfiVariables = true;
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
|
|
||||||
|
|
||||||
# mask dev-tpmrm0.device
|
# mask dev-tpmrm0.device
|
||||||
systemd.services.dev-tpmrm0.wantedBy = lib.mkForce[ ];
|
systemd.services.dev-tpmrm0.wantedBy = lib.mkForce [];
|
||||||
|
|
||||||
networking.hostName = "nixos"; # Define your hostname.
|
networking.hostName = "nixos"; # Define your hostname.
|
||||||
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
||||||
|
|
||||||
# flakes
|
# flakes
|
||||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
nix.settings.experimental-features = ["nix-command" "flakes"];
|
||||||
|
|
||||||
# Configure network proxy if necessary
|
# Configure network proxy if necessary
|
||||||
# networking.proxy.default = "http://user:password@proxy:port/";
|
# networking.proxy.default = "http://user:password@proxy:port/";
|
||||||
|
|
@ -92,14 +94,14 @@
|
||||||
users.users.luna = {
|
users.users.luna = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
description = "luna";
|
description = "luna";
|
||||||
extraGroups = [ "networkmanager" "wheel" ];
|
extraGroups = ["networkmanager" "wheel"];
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
# thunderbird
|
# thunderbird
|
||||||
gnome-software
|
gnome-software
|
||||||
git
|
git
|
||||||
neovim
|
neovim
|
||||||
rustup
|
rustup
|
||||||
vscode.fhs
|
vscode.fhs
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -112,9 +114,9 @@
|
||||||
# List packages installed in system profile. To search, run:
|
# List packages installed in system profile. To search, run:
|
||||||
# $ nix search wget
|
# $ nix search wget
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
# vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
|
# vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
|
||||||
# wget
|
# wget
|
||||||
gnome-menus
|
gnome-menus
|
||||||
];
|
];
|
||||||
|
|
||||||
# Some programs need SUID wrappers, can be configured further or are
|
# Some programs need SUID wrappers, can be configured further or are
|
||||||
|
|
|
||||||
|
|
@ -1,42 +1,46 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
# and may be overwritten by future invocations. Please make changes
|
# and may be overwritten by future invocations. Please make changes
|
||||||
# to /etc/nixos/configuration.nix instead.
|
# to /etc/nixos/configuration.nix instead.
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
config,
|
||||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
lib,
|
||||||
];
|
pkgs,
|
||||||
|
modulesPath,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
(modulesPath + "/installer/scan/not-detected.nix")
|
||||||
|
];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usb_storage" "ums_realtek" "usbhid" "sd_mod" "sr_mod" ];
|
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usb_storage" "ums_realtek" "usbhid" "sd_mod" "sr_mod"];
|
||||||
boot.initrd.kernelModules = [ "sg" ];
|
boot.initrd.kernelModules = ["sg"];
|
||||||
boot.kernelModules = [ "kvm-amd" ];
|
boot.kernelModules = ["kvm-amd"];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [];
|
||||||
|
|
||||||
fileSystems."/" =
|
fileSystems."/" = {
|
||||||
{ device = "/dev/disk/by-uuid/d3942c4d-eca8-41e2-afa7-57ba5704e86f";
|
device = "/dev/disk/by-uuid/d3942c4d-eca8-41e2-afa7-57ba5704e86f";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/mnt/sda1" =
|
fileSystems."/mnt/sda1" = {
|
||||||
{ device = "/dev/disk/by-uuid/22847bcf-830f-484b-9ff8-dec259e4a990";
|
device = "/dev/disk/by-uuid/22847bcf-830f-484b-9ff8-dec259e4a990";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/mnt/sdb1" =
|
fileSystems."/mnt/sdb1" = {
|
||||||
{ device = "/dev/disk/by-uuid/21301a6f-2937-421d-81ec-e2e9be139b0a";
|
device = "/dev/disk/by-uuid/21301a6f-2937-421d-81ec-e2e9be139b0a";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" =
|
fileSystems."/boot" = {
|
||||||
{ device = "/dev/disk/by-uuid/B44E-D001";
|
device = "/dev/disk/by-uuid/B44E-D001";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
options = [ "fmask=0077" "dmask=0077" ];
|
options = ["fmask=0077" "dmask=0077"];
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices =
|
swapDevices = [
|
||||||
[ { device = "/dev/disk/by-uuid/f054feb9-61b1-41f3-b0b2-6e48bfcc6655"; }
|
{device = "/dev/disk/by-uuid/f054feb9-61b1-41f3-b0b2-6e48bfcc6655";}
|
||||||
];
|
];
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
# 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
|
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,8 @@
|
||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
# Home Manager needs a bit of information about you and the paths it should
|
# Home Manager needs a bit of information about you and the paths it should
|
||||||
# manage.
|
# manage.
|
||||||
home.username = "luna";
|
home.username = "luna";
|
||||||
|
|
|
||||||
|
|
@ -1,25 +1,27 @@
|
||||||
{ pkgs, lib, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
programs.nvf = {
|
pkgs,
|
||||||
enable = true;
|
lib,
|
||||||
settings.vim = {
|
...
|
||||||
theme = {
|
}: {
|
||||||
enable = true;
|
programs.nvf = {
|
||||||
name = "catppuccin";
|
enable = true;
|
||||||
style = "macchiato";
|
settings.vim = {
|
||||||
};
|
theme = {
|
||||||
|
enable = true;
|
||||||
|
name = "catppuccin";
|
||||||
|
style = "macchiato";
|
||||||
|
};
|
||||||
|
|
||||||
statusline.lualine.enable = true;
|
statusline.lualine.enable = true;
|
||||||
telescope.enable = true;
|
telescope.enable = true;
|
||||||
|
|
||||||
languages = {
|
languages = {
|
||||||
enableLSP = true;
|
enableLSP = true;
|
||||||
enableTreesitter = true;
|
enableTreesitter = true;
|
||||||
|
|
||||||
nix.enable = true;
|
nix.enable = true;
|
||||||
rust.enable = true;
|
rust.enable = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue