Compare commits
7 Commits
34895d2982
...
934c78b494
Author | SHA1 | Date | |
---|---|---|---|
934c78b494 | |||
48223c6eb8 | |||
6917afdd12 | |||
7b31f4c0b1 | |||
79f9cb89b6 | |||
0f87c01fdc | |||
7f5cfe61e1 |
5
.editorconfig
Normal file
5
.editorconfig
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
root=true
|
||||||
|
|
||||||
|
[*]
|
||||||
|
indent_style: "tab"
|
||||||
|
indent_size: "2"
|
82
flake.lock
generated
Normal file
82
flake.lock
generated
Normal file
@ -0,0 +1,82 @@
|
|||||||
|
{
|
||||||
|
"nodes": {
|
||||||
|
"home-manager": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1627649712,
|
||||||
|
"narHash": "sha256-AJBasvMKpsyJmCLdjroBElCHY5AlalbVy+XY5vjbgXc=",
|
||||||
|
"owner": "rycee",
|
||||||
|
"repo": "home-manager",
|
||||||
|
"rev": "b39647e52ed3c0b989e9d5c965e598ae4c38d7ef",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "rycee",
|
||||||
|
"ref": "release-21.05",
|
||||||
|
"repo": "home-manager",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"nixpkgs": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1629033443,
|
||||||
|
"narHash": "sha256-Vo3TvQvR5hsd3incx/xOt6GFgTm651CYVauHS/irOFo=",
|
||||||
|
"owner": "nixos",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "8ac785da9843aa110caeed6c912875e46a415a11",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nixos",
|
||||||
|
"ref": "nixos-21.05",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"nur": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1629143403,
|
||||||
|
"narHash": "sha256-Z57DBF3MUTqTnJyYjqEN+DNZLrVukEJJotcxYPHNR/M=",
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "NUR",
|
||||||
|
"rev": "79a06a9145c61960dd4b5c2eda67e26276976db1",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "NUR",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": {
|
||||||
|
"inputs": {
|
||||||
|
"home-manager": "home-manager",
|
||||||
|
"nixpkgs": "nixpkgs",
|
||||||
|
"nur": "nur",
|
||||||
|
"unstable": "unstable"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unstable": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1629048390,
|
||||||
|
"narHash": "sha256-do7HuXFSKyj4ulMlRvGigNZCqOaGD9i0M3OLkFQgEAc=",
|
||||||
|
"owner": "nixos",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "e41ba38114055832e5ba4a851e9c00149eef3e4a",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nixos",
|
||||||
|
"ref": "nixos-unstable",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": "root",
|
||||||
|
"version": 7
|
||||||
|
}
|
33
flake.nix
Normal file
33
flake.nix
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
{
|
||||||
|
description = "Michael Thomas's NixOS configuration";
|
||||||
|
|
||||||
|
inputs = {
|
||||||
|
home-manager = {
|
||||||
|
url = "github:rycee/home-manager/release-21.05";
|
||||||
|
inputs = {
|
||||||
|
nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-21.05";
|
||||||
|
unstable.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
|
nur.url = "github:nix-community/NUR";
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs = inputs: {
|
||||||
|
nixosConfigurations = {
|
||||||
|
|
||||||
|
loft = inputs.nixpkgs.lib.nixosSystem {
|
||||||
|
system = "x86_64-linux";
|
||||||
|
modules = [
|
||||||
|
./modules/common.nix
|
||||||
|
./modules/containers.nix
|
||||||
|
|
||||||
|
./machines/loft/configuration.nix
|
||||||
|
];
|
||||||
|
specialArgs = { inherit inputs; };
|
||||||
|
};
|
||||||
|
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
126
machines/loft/configuration.nix
Normal file
126
machines/loft/configuration.nix
Normal file
@ -0,0 +1,126 @@
|
|||||||
|
# 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, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports =
|
||||||
|
[ # Include the results of the hardware scan.
|
||||||
|
./hardware-configuration.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
# Auto cleanup
|
||||||
|
nix = {
|
||||||
|
package = pkgs.nixUnstable;
|
||||||
|
extraOptions = ''
|
||||||
|
experimental-features = nix-command flakes
|
||||||
|
'';
|
||||||
|
autoOptimiseStore = true;
|
||||||
|
gc = {
|
||||||
|
automatic = true;
|
||||||
|
dates = "weekly";
|
||||||
|
options = "--delete-older-than 30d";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
nixpkgs.config = {
|
||||||
|
allowUnfree = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# Set your time zone.
|
||||||
|
time.timeZone = "America/New_York";
|
||||||
|
|
||||||
|
# Configure suspend to disk
|
||||||
|
systemd.sleep.extraConfig = ''
|
||||||
|
SuspendState=disk
|
||||||
|
SuspendMode=suspend
|
||||||
|
HibernateMode=platform shutdown
|
||||||
|
'';
|
||||||
|
|
||||||
|
##############
|
||||||
|
# NETWORKING #
|
||||||
|
##############
|
||||||
|
networking.useDHCP = false;
|
||||||
|
networking.interfaces.enp0s20u5u4.useDHCP = true;
|
||||||
|
networking.interfaces.enp4s0.useDHCP = true;
|
||||||
|
networking.interfaces.wlp5s0.useDHCP = true;
|
||||||
|
|
||||||
|
networking.hostName = "loft"; # Define your hostname.
|
||||||
|
networking.firewall = {
|
||||||
|
enable = true;
|
||||||
|
allowedTCPPorts = [ 80 8080 8000 443 8888 ];
|
||||||
|
allowedTCPPortRanges = [
|
||||||
|
{ from = 1714; to = 1764; }
|
||||||
|
];
|
||||||
|
allowedUDPPortRanges = [
|
||||||
|
{ from = 1714; to = 1764; }
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
# 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 = "en_US.UTF-8";
|
||||||
|
# console = {
|
||||||
|
# font = "Lat2-Terminus16";
|
||||||
|
# keyMap = "us";
|
||||||
|
# };
|
||||||
|
|
||||||
|
# Configure keymap in X11
|
||||||
|
# services.xserver.layout = "us";
|
||||||
|
# services.xserver.xkbOptions = "eurosign:e";
|
||||||
|
|
||||||
|
# Enable touchpad support (enabled default in most desktopManager).
|
||||||
|
# services.xserver.libinput.enable = true;
|
||||||
|
|
||||||
|
programs.zsh.enable = true;
|
||||||
|
|
||||||
|
users.defaultUserShell = pkgs.zsh;
|
||||||
|
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||||
|
users.users.michael = {
|
||||||
|
isNormalUser = true;
|
||||||
|
description = "Michael Thomas";
|
||||||
|
extraGroups = [ "wheel" "docker" "networkmanager" ]; # Enable ‘sudo’ for the user.
|
||||||
|
shell = pkgs.zsh;
|
||||||
|
};
|
||||||
|
|
||||||
|
# List packages installed in system profile. To search, run:
|
||||||
|
# $ nix search wget
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
wget micro
|
||||||
|
google-chrome
|
||||||
|
pkgs.gnome3.gnome-tweaks
|
||||||
|
gnomeExtensions.gsconnect
|
||||||
|
];
|
||||||
|
|
||||||
|
# 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 = [ ... ];
|
||||||
|
# networking.firewall.allowedUDPPorts = [ ... ];
|
||||||
|
# Or disable the firewall altogether.
|
||||||
|
# networking.firewall.enable = false;
|
||||||
|
|
||||||
|
# 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 = "20.09"; # Did you read the comment?
|
||||||
|
|
||||||
|
}
|
35
machines/loft/hardware-configuration.nix
Normal file
35
machines/loft/hardware-configuration.nix
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
# 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" "ehci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
|
||||||
|
boot.initrd.kernelModules = [ ];
|
||||||
|
boot.kernelModules = [ "kvm-intel" ];
|
||||||
|
boot.blacklistedKernelModules = [ "radeon" "amdgpu" ];
|
||||||
|
# boot.kernelParams = [ "radeon.si_support=0" "radeon.cik_support=0" "amdgpu.si_support=1" "amdgpu.cik_support=1" ];
|
||||||
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
fileSystems."/" = {
|
||||||
|
device = "/dev/disk/by-uuid/76737cbf-9b6b-4236-ac9d-7d0daa9c1bf2";
|
||||||
|
fsType = "ext4";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/boot" = {
|
||||||
|
device = "/dev/disk/by-uuid/BA82-2808";
|
||||||
|
fsType = "vfat";
|
||||||
|
};
|
||||||
|
|
||||||
|
swapDevices = [
|
||||||
|
{
|
||||||
|
device = "/dev/disk/by-uuid/9943357a-de4b-498b-b408-0b79b74435d1";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
powerManagement.cpuFreqGovernor = lib.mkDefault "performance";
|
||||||
|
|
||||||
|
hardware.cpu.intel.updateMicrocode = true;
|
||||||
|
}
|
5
modules/auto-upgrades.nix
Normal file
5
modules/auto-upgrades.nix
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
# Enable automatic updates
|
||||||
|
system.autoUpgrade.enable = true;
|
||||||
|
system.autoUpgrade.allowReboot = false;
|
||||||
|
}
|
9
modules/avahi.nix
Normal file
9
modules/avahi.nix
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
# Enable Avahi Network Discovery
|
||||||
|
services.avahi = {
|
||||||
|
enable = true;
|
||||||
|
nssmdns = true;
|
||||||
|
publish.enable = true;
|
||||||
|
publish.addresses = true;
|
||||||
|
};
|
||||||
|
}
|
6
modules/bootloader.nix
Normal file
6
modules/bootloader.nix
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
# Use the systemd-boot EFI boot loader.
|
||||||
|
boot.loader.systemd-boot.enable = true;
|
||||||
|
boot.loader.efi.canTouchEfiVariables = false;
|
||||||
|
boot.plymouth.enable = true;
|
||||||
|
}
|
12
modules/common.nix
Normal file
12
modules/common.nix
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
imports = [
|
||||||
|
./auto-upgrades.nix
|
||||||
|
./avahi.nix
|
||||||
|
./bootloader.nix
|
||||||
|
./cups.nix
|
||||||
|
./flatpak.nix
|
||||||
|
./fonts.nix
|
||||||
|
./gnome.nix
|
||||||
|
./sound.nix
|
||||||
|
];
|
||||||
|
}
|
5
modules/containers.nix
Normal file
5
modules/containers.nix
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
# Enable Docker
|
||||||
|
# TODO: podman
|
||||||
|
virtualisation.docker.enable = true;
|
||||||
|
}
|
7
modules/cups.nix
Normal file
7
modules/cups.nix
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
{ pkgs, ... }: {
|
||||||
|
# Enable CUPS to print documents.
|
||||||
|
services.printing = {
|
||||||
|
enable = true;
|
||||||
|
drivers = [ pkgs.epson-escpr2 ];
|
||||||
|
};
|
||||||
|
}
|
6
modules/flatpak.nix
Normal file
6
modules/flatpak.nix
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
# Enable Flatpak support
|
||||||
|
services.flatpak.enable = true;
|
||||||
|
services.fwupd.enable = true;
|
||||||
|
appstream.enable = true;
|
||||||
|
}
|
23
modules/fonts.nix
Normal file
23
modules/fonts.nix
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
{ pkgs, ... }: {
|
||||||
|
# Font Settings
|
||||||
|
fonts = {
|
||||||
|
fonts = with pkgs; [
|
||||||
|
roboto
|
||||||
|
inter
|
||||||
|
];
|
||||||
|
fontconfig = {
|
||||||
|
localConf = ''
|
||||||
|
<alias>
|
||||||
|
<family>system-ui</family>
|
||||||
|
<prefer>
|
||||||
|
<family>Inter</family>
|
||||||
|
<family>Roboto</family>
|
||||||
|
<family>Cantarell</family>
|
||||||
|
<family>Liberation Sans</family>
|
||||||
|
<family>DejaVu Sans</family>
|
||||||
|
</prefer>
|
||||||
|
</alias>
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
8
modules/gnome.nix
Normal file
8
modules/gnome.nix
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
# Enable the GNOME Desktop Environment.
|
||||||
|
services.xserver.enable = true;
|
||||||
|
services.xserver.displayManager.gdm.enable = true;
|
||||||
|
services.xserver.desktopManager.gnome.enable = true;
|
||||||
|
services.gnome.chrome-gnome-shell.enable = true;
|
||||||
|
programs.dconf.enable = true;
|
||||||
|
}
|
5
modules/sound.nix
Normal file
5
modules/sound.nix
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
# Enable sound.
|
||||||
|
sound.enable = true;
|
||||||
|
hardware.pulseaudio.enable = true;
|
||||||
|
}
|
@ -1,3 +0,0 @@
|
|||||||
{
|
|
||||||
allowUnfree = true;
|
|
||||||
}
|
|
@ -1,22 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
../../modules/home-manager.nix
|
|
||||||
../../modules/dev.nix
|
|
||||||
../../modules/fonts.nix
|
|
||||||
../../modules/git.nix
|
|
||||||
../../modules/git_nixos.nix
|
|
||||||
../../modules/gnome.nix
|
|
||||||
../../modules/vscode.nix
|
|
||||||
../../modules/zsh.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
neofetch
|
|
||||||
fortune
|
|
||||||
google-chrome
|
|
||||||
firefox
|
|
||||||
];
|
|
||||||
|
|
||||||
}
|
|
@ -1,3 +0,0 @@
|
|||||||
{
|
|
||||||
allowUnfree = true;
|
|
||||||
}
|
|
@ -1,13 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
../../modules/home-manager.nix
|
|
||||||
../../modules/zsh.nix
|
|
||||||
../../modules/dev.nix
|
|
||||||
../../modules/fonts.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
neofetch
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,3 +0,0 @@
|
|||||||
{
|
|
||||||
allowUnfree = true;
|
|
||||||
}
|
|
@ -1,20 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
../../modules/home-manager.nix
|
|
||||||
../../modules/git.nix
|
|
||||||
../../modules/zsh.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
neofetch
|
|
||||||
pfetch
|
|
||||||
fortune
|
|
||||||
];
|
|
||||||
|
|
||||||
programs.zsh.shellAliases = {
|
|
||||||
code = "/mnt/c/Program\\ Files/Microsoft\\ VS\\ Code/Code.exe";
|
|
||||||
};
|
|
||||||
|
|
||||||
}
|
|
@ -1,7 +0,0 @@
|
|||||||
{ config, pkgs, libs, ... }:
|
|
||||||
{
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
nodePackages.yarn
|
|
||||||
php
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,10 +0,0 @@
|
|||||||
{ config, pkgs, libs, ... }:
|
|
||||||
{
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
(nerdfonts.override { fonts = [ "FiraCode" ]; })
|
|
||||||
google-fonts
|
|
||||||
inter
|
|
||||||
];
|
|
||||||
|
|
||||||
fonts.fontconfig.enable = true;
|
|
||||||
}
|
|
@ -1,13 +0,0 @@
|
|||||||
{ config, pkgs, libs, ... }:
|
|
||||||
{
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
git-lfs
|
|
||||||
];
|
|
||||||
|
|
||||||
# Use pkgs.gitAndTools.gitFull in order to get libsecret support
|
|
||||||
programs.git = {
|
|
||||||
enable = true;
|
|
||||||
userEmail = "michaelhthomas@outlook.com";
|
|
||||||
userName = "Michael Thomas";
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,10 +0,0 @@
|
|||||||
{ config, pkgs, libs, ... }:
|
|
||||||
{
|
|
||||||
# Use pkgs.gitAndTools.gitFull in order to get libsecret support
|
|
||||||
programs.git = {
|
|
||||||
package = pkgs.gitAndTools.gitFull;
|
|
||||||
extraConfig = {
|
|
||||||
credential.helper = "libsecret";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,33 +0,0 @@
|
|||||||
{ config, pkgs, libs, ... }:
|
|
||||||
{
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
gnomeExtensions.caffeine
|
|
||||||
gnomeExtensions.paperwm
|
|
||||||
gnomeExtensions.remove-dropdown-arrows
|
|
||||||
gnomeExtensions.impatience
|
|
||||||
];
|
|
||||||
|
|
||||||
gtk = {
|
|
||||||
enable = true;
|
|
||||||
theme = {
|
|
||||||
name = "Adwaita-dark";
|
|
||||||
# package = pkgs.arc-theme;
|
|
||||||
};
|
|
||||||
font.name = "Inter 11";
|
|
||||||
iconTheme = {
|
|
||||||
name = "Papirus";
|
|
||||||
package = pkgs.papirus-icon-theme;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.gnome-terminal = {
|
|
||||||
enable = true;
|
|
||||||
profile = {
|
|
||||||
"5ddfe964-7ee6-4131-b449-26bdd97518f7" = {
|
|
||||||
default = true;
|
|
||||||
visibleName = "Michael";
|
|
||||||
font = "FiraCode Nerd Font 12";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,20 +0,0 @@
|
|||||||
{ config, pkgs, libs, ... }:
|
|
||||||
{
|
|
||||||
# Let Home Manager install and manage itself.
|
|
||||||
programs.home-manager.enable = true;
|
|
||||||
|
|
||||||
# Home Manager needs a bit of information about you and the
|
|
||||||
# paths it should manage.
|
|
||||||
home.username = builtins.getEnv "USER";
|
|
||||||
home.homeDirectory = builtins.getEnv "HOME";
|
|
||||||
|
|
||||||
# This value determines the Home Manager release that your
|
|
||||||
# configuration is compatible with. This helps avoid breakage
|
|
||||||
# when a new Home Manager release introduces backwards
|
|
||||||
# incompatible changes.
|
|
||||||
#
|
|
||||||
# You can update Home Manager without changing this value. See
|
|
||||||
# the Home Manager release notes for a list of state version
|
|
||||||
# changes in each release.
|
|
||||||
home.stateVersion = "21.03";
|
|
||||||
}
|
|
@ -1,15 +0,0 @@
|
|||||||
{ config, pkgs, libs, ... }:
|
|
||||||
{
|
|
||||||
programs = {
|
|
||||||
vscode = {
|
|
||||||
enable = true;
|
|
||||||
extensions = [
|
|
||||||
pkgs.vscode-extensions.bbenoist.Nix
|
|
||||||
];
|
|
||||||
# userSettings = {
|
|
||||||
# "editor.fontFamily" = "'FiraCode Nerd Font', 'Droid Sans Mono', 'monospace', monospace, 'Droid Sans Fallback'";
|
|
||||||
# "editor.tabSize" = 2;
|
|
||||||
# };
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,46 +0,0 @@
|
|||||||
{ config, pkgs, libs, ... }:
|
|
||||||
{
|
|
||||||
programs.zsh = {
|
|
||||||
enable = true;
|
|
||||||
plugins = [
|
|
||||||
{
|
|
||||||
name = "zsh-nix-shell";
|
|
||||||
file = "nix-shell.plugin.zsh";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "chisui";
|
|
||||||
repo = "zsh-nix-shell";
|
|
||||||
rev = "v0.1.0";
|
|
||||||
sha256 = "0snhch9hfy83d4amkyxx33izvkhbwmindy0zjjk28hih1a9l2jmx";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
prezto = {
|
|
||||||
enable = true;
|
|
||||||
pmodules = [
|
|
||||||
"archive"
|
|
||||||
"docker"
|
|
||||||
"environment"
|
|
||||||
"git"
|
|
||||||
"terminal"
|
|
||||||
"editor"
|
|
||||||
"history"
|
|
||||||
"directory"
|
|
||||||
"spectrum"
|
|
||||||
"utility"
|
|
||||||
"completion"
|
|
||||||
"command-not-found"
|
|
||||||
"syntax-highlighting"
|
|
||||||
"history-substring-search"
|
|
||||||
"autosuggestions"
|
|
||||||
"prompt"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
programs.starship = {
|
|
||||||
enable = true;
|
|
||||||
enableZshIntegration = true;
|
|
||||||
settings = {
|
|
||||||
character.success_symbol = "[➜](green)";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1 +0,0 @@
|
|||||||
/etc/nixos/configuration.nix
|
|
@ -1 +0,0 @@
|
|||||||
/etc/nixos/hardware-configuration.nix
|
|
2
user/.gitignore
vendored
Normal file
2
user/.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
/home.nix
|
||||||
|
/config.nix
|
3
user/machines/loft/config.nix
Normal file
3
user/machines/loft/config.nix
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
allowUnfree = true;
|
||||||
|
}
|
22
user/machines/loft/home.nix
Normal file
22
user/machines/loft/home.nix
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
../../modules/home-manager.nix
|
||||||
|
../../modules/dev.nix
|
||||||
|
../../modules/fonts.nix
|
||||||
|
../../modules/git.nix
|
||||||
|
../../modules/git_nixos.nix
|
||||||
|
../../modules/gnome.nix
|
||||||
|
../../modules/vscode.nix
|
||||||
|
../../modules/zsh.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
neofetch
|
||||||
|
fortune
|
||||||
|
google-chrome
|
||||||
|
firefox
|
||||||
|
];
|
||||||
|
|
||||||
|
}
|
3
user/machines/mac/config.nix
Normal file
3
user/machines/mac/config.nix
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
allowUnfree = true;
|
||||||
|
}
|
13
user/machines/mac/home.nix
Normal file
13
user/machines/mac/home.nix
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
../../modules/home-manager.nix
|
||||||
|
../../modules/zsh.nix
|
||||||
|
../../modules/dev.nix
|
||||||
|
../../modules/fonts.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
neofetch
|
||||||
|
];
|
||||||
|
}
|
3
user/machines/wsl/config.nix
Normal file
3
user/machines/wsl/config.nix
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
allowUnfree = true;
|
||||||
|
}
|
20
user/machines/wsl/home.nix
Normal file
20
user/machines/wsl/home.nix
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
../../modules/home-manager.nix
|
||||||
|
../../modules/git.nix
|
||||||
|
../../modules/zsh.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
neofetch
|
||||||
|
pfetch
|
||||||
|
fortune
|
||||||
|
];
|
||||||
|
|
||||||
|
programs.zsh.shellAliases = {
|
||||||
|
code = "/mnt/c/Program\\ Files/Microsoft\\ VS\\ Code/Code.exe";
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
7
user/modules/dev.nix
Normal file
7
user/modules/dev.nix
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
{ config, pkgs, libs, ... }:
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
nodePackages.yarn
|
||||||
|
php
|
||||||
|
];
|
||||||
|
}
|
10
user/modules/fonts.nix
Normal file
10
user/modules/fonts.nix
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
{ config, pkgs, libs, ... }:
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
(nerdfonts.override { fonts = [ "FiraCode" ]; })
|
||||||
|
google-fonts
|
||||||
|
inter
|
||||||
|
];
|
||||||
|
|
||||||
|
fonts.fontconfig.enable = true;
|
||||||
|
}
|
13
user/modules/git.nix
Normal file
13
user/modules/git.nix
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
{ config, pkgs, libs, ... }:
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
git-lfs
|
||||||
|
];
|
||||||
|
|
||||||
|
# Use pkgs.gitAndTools.gitFull in order to get libsecret support
|
||||||
|
programs.git = {
|
||||||
|
enable = true;
|
||||||
|
userEmail = "michaelhthomas@outlook.com";
|
||||||
|
userName = "Michael Thomas";
|
||||||
|
};
|
||||||
|
}
|
10
user/modules/git_nixos.nix
Normal file
10
user/modules/git_nixos.nix
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
{ config, pkgs, libs, ... }:
|
||||||
|
{
|
||||||
|
# Use pkgs.gitAndTools.gitFull in order to get libsecret support
|
||||||
|
programs.git = {
|
||||||
|
package = pkgs.gitAndTools.gitFull;
|
||||||
|
extraConfig = {
|
||||||
|
credential.helper = "libsecret";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
34
user/modules/gnome.nix
Normal file
34
user/modules/gnome.nix
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
{ config, pkgs, libs, ... }:
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
gnomeExtensions.caffeine
|
||||||
|
gnomeExtensions.paperwm
|
||||||
|
gnomeExtensions.cleaner-overview
|
||||||
|
gnomeExtensions.vertical-overview
|
||||||
|
gnomeExtensions.disable-workspace-switch-animation-for-gnome-40
|
||||||
|
];
|
||||||
|
|
||||||
|
gtk = {
|
||||||
|
enable = true;
|
||||||
|
theme = {
|
||||||
|
name = "Adwaita-dark";
|
||||||
|
# package = pkgs.arc-theme;
|
||||||
|
};
|
||||||
|
font.name = "Inter 11";
|
||||||
|
iconTheme = {
|
||||||
|
name = "Papirus";
|
||||||
|
package = pkgs.papirus-icon-theme;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.gnome-terminal = {
|
||||||
|
enable = true;
|
||||||
|
profile = {
|
||||||
|
"5ddfe964-7ee6-4131-b449-26bdd97518f7" = {
|
||||||
|
default = true;
|
||||||
|
visibleName = "Michael";
|
||||||
|
font = "FiraCode Nerd Font 12";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
20
user/modules/home-manager.nix
Normal file
20
user/modules/home-manager.nix
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
{ config, pkgs, libs, ... }:
|
||||||
|
{
|
||||||
|
# Let Home Manager install and manage itself.
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
|
||||||
|
# Home Manager needs a bit of information about you and the
|
||||||
|
# paths it should manage.
|
||||||
|
home.username = builtins.getEnv "USER";
|
||||||
|
home.homeDirectory = builtins.getEnv "HOME";
|
||||||
|
|
||||||
|
# This value determines the Home Manager release that your
|
||||||
|
# configuration is compatible with. This helps avoid breakage
|
||||||
|
# when a new Home Manager release introduces backwards
|
||||||
|
# incompatible changes.
|
||||||
|
#
|
||||||
|
# You can update Home Manager without changing this value. See
|
||||||
|
# the Home Manager release notes for a list of state version
|
||||||
|
# changes in each release.
|
||||||
|
home.stateVersion = "21.03";
|
||||||
|
}
|
15
user/modules/vscode.nix
Normal file
15
user/modules/vscode.nix
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
{ config, pkgs, libs, ... }:
|
||||||
|
{
|
||||||
|
programs = {
|
||||||
|
vscode = {
|
||||||
|
enable = true;
|
||||||
|
extensions = [
|
||||||
|
pkgs.vscode-extensions.bbenoist.Nix
|
||||||
|
];
|
||||||
|
# userSettings = {
|
||||||
|
# "editor.fontFamily" = "'FiraCode Nerd Font', 'Droid Sans Mono', 'monospace', monospace, 'Droid Sans Fallback'";
|
||||||
|
# "editor.tabSize" = 2;
|
||||||
|
# };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
46
user/modules/zsh.nix
Normal file
46
user/modules/zsh.nix
Normal file
@ -0,0 +1,46 @@
|
|||||||
|
{ config, pkgs, libs, ... }:
|
||||||
|
{
|
||||||
|
programs.zsh = {
|
||||||
|
enable = true;
|
||||||
|
plugins = [
|
||||||
|
{
|
||||||
|
name = "zsh-nix-shell";
|
||||||
|
file = "nix-shell.plugin.zsh";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "chisui";
|
||||||
|
repo = "zsh-nix-shell";
|
||||||
|
rev = "v0.1.0";
|
||||||
|
sha256 = "0snhch9hfy83d4amkyxx33izvkhbwmindy0zjjk28hih1a9l2jmx";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
];
|
||||||
|
prezto = {
|
||||||
|
enable = true;
|
||||||
|
pmodules = [
|
||||||
|
"archive"
|
||||||
|
"docker"
|
||||||
|
"environment"
|
||||||
|
"git"
|
||||||
|
"terminal"
|
||||||
|
"editor"
|
||||||
|
"history"
|
||||||
|
"directory"
|
||||||
|
"spectrum"
|
||||||
|
"utility"
|
||||||
|
"completion"
|
||||||
|
"command-not-found"
|
||||||
|
"syntax-highlighting"
|
||||||
|
"history-substring-search"
|
||||||
|
"autosuggestions"
|
||||||
|
"prompt"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
programs.starship = {
|
||||||
|
enable = true;
|
||||||
|
enableZshIntegration = true;
|
||||||
|
settings = {
|
||||||
|
character.success_symbol = "[➜](green)";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
11
user/overlays/paperwm.nix
Normal file
11
user/overlays/paperwm.nix
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
self: super: {
|
||||||
|
gnomeExtensions = super.gnomeExtensions // {
|
||||||
|
paperwm = super.gnomeExtensions.paperwm.overrideDerivation (old: {
|
||||||
|
version = "pre-40.0";
|
||||||
|
src = builtins.fetchGit {
|
||||||
|
url = https://github.com/paperwm/paperwm.git;
|
||||||
|
ref = "next-release";
|
||||||
|
};
|
||||||
|
});
|
||||||
|
};
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user