Compare commits
7 commits
1abf3d503d
...
597b50ebef
Author | SHA1 | Date | |
---|---|---|---|
Geoffrey Frogeye | 597b50ebef | ||
Geoffrey Frogeye | 6d98d85642 | ||
Geoffrey Frogeye | e013bcfdba | ||
Geoffrey Frogeye | 25130195ec | ||
Geoffrey Frogeye | 7506f55468 | ||
Geoffrey Frogeye | c954f0df5f | ||
Geoffrey Frogeye | 3477528dd5 |
|
@ -1,8 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# TODO Flakes
|
||||
|
||||
nix-channel --add https://nixos.org/channels/nixos-23.11 nixpkgs
|
||||
nix-channel --add https://github.com/nix-community/home-manager/archive/release-23.11.tar.gz home-manager
|
||||
nix-channel --add https://github.com/NixOS/nixos-hardware/archive/8772491ed75f150f02552c60694e1beff9f46013.tar.gz nixos-hardware
|
||||
nix-channel --update
|
|
@ -2,6 +2,9 @@
|
|||
#! nix-shell -i bash
|
||||
#! nix-shell -p bash nix-output-monitor
|
||||
|
||||
echo FIXME Not flakes ready
|
||||
exit 1
|
||||
|
||||
set -euo pipefail
|
||||
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
|
||||
|
||||
|
|
|
@ -2,6 +2,9 @@
|
|||
#! nix-shell -i bash
|
||||
#! nix-shell -p bash nix-output-monitor
|
||||
|
||||
echo FIXME Not flakes ready
|
||||
exit 1
|
||||
|
||||
set -euo pipefail
|
||||
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
|
||||
|
||||
|
|
|
@ -1,9 +1,5 @@
|
|||
{ lib, ... }:
|
||||
{ lib, nixos-hardware, ... }:
|
||||
{
|
||||
imports = [
|
||||
<nixos-hardware/dell/g3/3779>
|
||||
];
|
||||
|
||||
# UEFI works here, and variables can be touched
|
||||
boot.loader = {
|
||||
efi.canTouchEfiVariables = lib.mkDefault true;
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../os
|
||||
./options.nix
|
||||
./hardware.nix
|
||||
./dk.nix
|
||||
|
|
|
@ -1,12 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../hm
|
||||
../curacao/options.nix
|
||||
];
|
||||
|
||||
home.username = "gnix";
|
||||
home.homeDirectory = "/home/gnix";
|
||||
|
||||
frogeye.desktop.nixGLIntel = true;
|
||||
}
|
|
@ -1,2 +0,0 @@
|
|||
{ ... } @ args:
|
||||
import ../dk/single_uefi_btrfs.nix (args // { id = "usb-Kingston_DataTraveler_3.0_E0D55EA57414F510489F0F1A-0:0"; name = "curacao_usb"; })
|
|
@ -1,22 +0,0 @@
|
|||
{ pkgs, config, ... }:
|
||||
{
|
||||
imports = [
|
||||
../os
|
||||
../curacao/options.nix
|
||||
../curacao/hardware.nix
|
||||
./dk.nix
|
||||
];
|
||||
|
||||
networking.hostName = "curacao_usb";
|
||||
|
||||
# It's a removable drive, so no touching EFI vars
|
||||
# (quite a lot of stuff to set for that!)
|
||||
boot.loader = {
|
||||
efi.canTouchEfiVariables = false;
|
||||
grub = {
|
||||
efiInstallAsRemovable = true;
|
||||
device = "nodev";
|
||||
};
|
||||
};
|
||||
|
||||
}
|
502
flake.lock
Normal file
502
flake.lock
Normal file
|
@ -0,0 +1,502 @@
|
|||
{
|
||||
"nodes": {
|
||||
"base16": {
|
||||
"inputs": {
|
||||
"fromYaml": "fromYaml"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1689633990,
|
||||
"narHash": "sha256-iwvQg2Vx0IIDWZaKo8Xmzxlv1YPHg+Kp/QSv8dRv0RY=",
|
||||
"owner": "SenchoPens",
|
||||
"repo": "base16.nix",
|
||||
"rev": "dddf2e1c04845d43c89a8e9e37d574519649a404",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "SenchoPens",
|
||||
"repo": "base16.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"base16-alacritty": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1674275109,
|
||||
"narHash": "sha256-Adwx9yP70I6mJrjjODOgZJjt4OPPe8gJu7UuBboXO4M=",
|
||||
"owner": "aarowill",
|
||||
"repo": "base16-alacritty",
|
||||
"rev": "63d8ae5dfefe5db825dd4c699d0cdc2fc2c3eaf7",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "aarowill",
|
||||
"repo": "base16-alacritty",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"base16-fish": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1622559957,
|
||||
"narHash": "sha256-PebymhVYbL8trDVVXxCvZgc0S5VxI7I1Hv4RMSquTpA=",
|
||||
"owner": "tomyun",
|
||||
"repo": "base16-fish",
|
||||
"rev": "2f6dd973a9075dabccd26f1cded09508180bf5fe",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "tomyun",
|
||||
"repo": "base16-fish",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"base16-foot": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1696725948,
|
||||
"narHash": "sha256-65bz2bUL/yzZ1c8/GQASnoiGwaF8DczlxJtzik1c0AU=",
|
||||
"owner": "tinted-theming",
|
||||
"repo": "base16-foot",
|
||||
"rev": "eedbcfa30de0a4baa03e99f5e3ceb5535c2755ce",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "tinted-theming",
|
||||
"repo": "base16-foot",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"base16-helix": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1696727917,
|
||||
"narHash": "sha256-FVrbPk+NtMra0jtlC5oxyNchbm8FosmvXIatkRbYy1g=",
|
||||
"owner": "tinted-theming",
|
||||
"repo": "base16-helix",
|
||||
"rev": "dbe1480d99fe80f08df7970e471fac24c05f2ddb",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "tinted-theming",
|
||||
"repo": "base16-helix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"base16-kitty": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1665001328,
|
||||
"narHash": "sha256-aRaizTYPpuWEcvoYE9U+YRX+Wsc8+iG0guQJbvxEdJY=",
|
||||
"owner": "kdrag0n",
|
||||
"repo": "base16-kitty",
|
||||
"rev": "06bb401fa9a0ffb84365905ffbb959ae5bf40805",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "kdrag0n",
|
||||
"repo": "base16-kitty",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"base16-tmux": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1696725902,
|
||||
"narHash": "sha256-wDPg5elZPcQpu7Df0lI5O8Jv4A3T6jUQIVg63KDU+3Q=",
|
||||
"owner": "tinted-theming",
|
||||
"repo": "base16-tmux",
|
||||
"rev": "c02050bebb60dbb20cb433cd4d8ce668ecc11ba7",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "tinted-theming",
|
||||
"repo": "base16-tmux",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"base16-vim": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1663659192,
|
||||
"narHash": "sha256-uJvaYYDMXvoo0fhBZUhN8WBXeJ87SRgof6GEK2efFT0=",
|
||||
"owner": "chriskempson",
|
||||
"repo": "base16-vim",
|
||||
"rev": "3be3cd82cd31acfcab9a41bad853d9c68d30478d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "chriskempson",
|
||||
"repo": "base16-vim",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"disko": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1704318910,
|
||||
"narHash": "sha256-wOIJwAsnZhM0NlFRwYJRgO4Lldh8j9viyzwQXtrbNtM=",
|
||||
"owner": "nix-community",
|
||||
"repo": "disko",
|
||||
"rev": "aef9a509db64a081186af2dc185654d78dc8e344",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"id": "disko",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1673956053,
|
||||
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat_2": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1673956053,
|
||||
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils": {
|
||||
"locked": {
|
||||
"lastModified": 1659877975,
|
||||
"narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils_2": {
|
||||
"inputs": {
|
||||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1701680307,
|
||||
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils_3": {
|
||||
"inputs": {
|
||||
"systems": "systems_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1685518550,
|
||||
"narHash": "sha256-o2d0KcvaXzTrPRIo0kOLV0/QXHhDQ5DTi+OxcjO8xqY=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "a1720a10a6cfe8234c0e93907ffe81be440f4cef",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"fromYaml": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1689549921,
|
||||
"narHash": "sha256-iX0pk/uB019TdBGlaJEWvBCfydT6sRq+eDcGPifVsCM=",
|
||||
"owner": "SenchoPens",
|
||||
"repo": "fromYaml",
|
||||
"rev": "11fbbbfb32e3289d3c631e0134a23854e7865c84",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "SenchoPens",
|
||||
"repo": "fromYaml",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"gitignore": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixvim",
|
||||
"pre-commit-hooks",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1660459072,
|
||||
"narHash": "sha256-8DFJjXG8zqoONA1vXtgeKXy68KdJL5UaXR8NtVMUbx8=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"rev": "a20de23b925fd8264fd7fad6454652e142fd7f73",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1704099619,
|
||||
"narHash": "sha256-QRVMkdxLmv+aKGjcgeEg31xtJEIsYq4i1Kbyw5EPS6g=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "7e398b3d76bc1503171b1364c9d4a07ac06f3851",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"id": "home-manager",
|
||||
"ref": "release-23.11",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"home-manager_2": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"stylix",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1700847865,
|
||||
"narHash": "sha256-uWaOIemGl9LF813MW0AEgCBpKwFo2t1Wv3BZc6e5Frw=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "8cedd63eede4c22deb192f1721dd67e7460e1ebe",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixgl": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1685908677,
|
||||
"narHash": "sha256-E4zUPEUFyVWjVm45zICaHRpfGepfkE9Z2OECV9HXfA4=",
|
||||
"owner": "guibou",
|
||||
"repo": "nixGL",
|
||||
"rev": "489d6b095ab9d289fe11af0219a9ff00fe87c7c5",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "guibou",
|
||||
"repo": "nixGL",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixos-hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1704458188,
|
||||
"narHash": "sha256-f6BYEuIqnbrs6J/9m1/1VdkJ6d63hO9kUC09kTPuOqE=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixos-hardware",
|
||||
"rev": "172385318068519900a7d71c1024242fa6af75f0",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"id": "nixos-hardware",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1704420045,
|
||||
"narHash": "sha256-C36QmoJd5tdQ5R9MC1jM7fBkZW9zBUqbUCsgwS6j4QU=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "c1be43e8e837b8dbee2b3665a007e761680f0c3d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"id": "nixpkgs",
|
||||
"ref": "nixos-23.11",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"nixpkgs-stable": {
|
||||
"locked": {
|
||||
"lastModified": 1685801374,
|
||||
"narHash": "sha256-otaSUoFEMM+LjBI1XL/xGB5ao6IwnZOXc47qhIgJe8U=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "c37ca420157f4abc31e26f436c1145f8951ff373",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-23.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixvim": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils_2",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
],
|
||||
"pre-commit-hooks": "pre-commit-hooks"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1702044539,
|
||||
"narHash": "sha256-TNmEd6MipLxsrWromxqNfU4y17MoBr15QF7iEOagPy8=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nixvim",
|
||||
"rev": "c96d7b46d05a78e695ed1c725d1596b65509b4f9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "nixvim",
|
||||
"rev": "c96d7b46d05a78e695ed1c725d1596b65509b4f9",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"pre-commit-hooks": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat",
|
||||
"flake-utils": "flake-utils_3",
|
||||
"gitignore": "gitignore",
|
||||
"nixpkgs": [
|
||||
"nixvim",
|
||||
"nixpkgs"
|
||||
],
|
||||
"nixpkgs-stable": "nixpkgs-stable"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1700922917,
|
||||
"narHash": "sha256-ej2fch/T584b5K9sk1UhmZF7W6wEfDHuoUYpFN8dtvM=",
|
||||
"owner": "cachix",
|
||||
"repo": "pre-commit-hooks.nix",
|
||||
"rev": "e5ee5c5f3844550c01d2131096c7271cec5e9b78",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "cachix",
|
||||
"repo": "pre-commit-hooks.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"disko": "disko",
|
||||
"home-manager": "home-manager",
|
||||
"nixgl": "nixgl",
|
||||
"nixos-hardware": "nixos-hardware",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixvim": "nixvim",
|
||||
"stylix": "stylix"
|
||||
}
|
||||
},
|
||||
"stylix": {
|
||||
"inputs": {
|
||||
"base16": "base16",
|
||||
"base16-alacritty": "base16-alacritty",
|
||||
"base16-fish": "base16-fish",
|
||||
"base16-foot": "base16-foot",
|
||||
"base16-helix": "base16-helix",
|
||||
"base16-kitty": "base16-kitty",
|
||||
"base16-tmux": "base16-tmux",
|
||||
"base16-vim": "base16-vim",
|
||||
"flake-compat": "flake-compat_2",
|
||||
"home-manager": "home-manager_2",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1704308480,
|
||||
"narHash": "sha256-88ICCdJyYYtsolRnPhI9IF+bhUIVUyhJ7nrKcKPgf6M=",
|
||||
"owner": "danth",
|
||||
"repo": "stylix",
|
||||
"rev": "9bc1900b6888efdda39c2e02c7c8666911b72608",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "danth",
|
||||
"repo": "stylix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems_2": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
88
flake.nix
Normal file
88
flake.nix
Normal file
|
@ -0,0 +1,88 @@
|
|||
{
|
||||
description = "Geoffrey Frogeye's base configurations";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "nixpkgs/nixos-23.11";
|
||||
# OS
|
||||
disko = {
|
||||
url = "disko";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
nixos-hardware.url = "nixos-hardware";
|
||||
# HM
|
||||
home-manager = {
|
||||
url = "home-manager/release-23.11";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
stylix = {
|
||||
url = "github:danth/stylix";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
nixvim = {
|
||||
url = "github:nix-community/nixvim/c96d7b46d05a78e695ed1c725d1596b65509b4f9";
|
||||
# 24.05 Anything after this commit works
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
nixgl = {
|
||||
url = "github:guibou/nixGL";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, disko, nixos-hardware, home-manager, stylix, nixvim, nixgl, ... }:
|
||||
let
|
||||
sharedOverlays = [
|
||||
nixgl.overlay
|
||||
];
|
||||
lib = {
|
||||
nixosSystem = { system, modules }: nixpkgs.lib.nixosSystem {
|
||||
inherit system;
|
||||
modules = modules ++ [
|
||||
self.nixosModules.dotfiles
|
||||
{
|
||||
nixpkgs.overlays = sharedOverlays;
|
||||
home-manager.sharedModules = [ self.homeManagerModules.dotfiles ];
|
||||
}
|
||||
];
|
||||
};
|
||||
homeManagerConfiguration = { system, modules }: home-manager.lib.homeManagerConfiguration {
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
overlays = sharedOverlays;
|
||||
};
|
||||
modules = modules ++ [ self.homeManagerModules.dotfiles ];
|
||||
};
|
||||
};
|
||||
in
|
||||
{
|
||||
lib = lib;
|
||||
nixosModules.dotfiles = {
|
||||
imports = [
|
||||
./os
|
||||
disko.nixosModules.disko
|
||||
home-manager.nixosModules.home-manager
|
||||
];
|
||||
};
|
||||
homeManagerModules.dotfiles = {
|
||||
imports = [
|
||||
./hm
|
||||
stylix.homeManagerModules.stylix
|
||||
nixvim.homeManagerModules.nixvim
|
||||
];
|
||||
};
|
||||
nixosConfigurations.curacao = lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
./curacao/os.nix
|
||||
nixos-hardware.nixosModules.dell-g3-3779
|
||||
];
|
||||
};
|
||||
nixosConfigurations.pindakaas = lib.nixosSystem {
|
||||
system = "aarch64-linux";
|
||||
modules = [
|
||||
./pindakaas/os.nix
|
||||
nixos-hardware.nixosModules.pine64-pinebook-pro
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,6 +0,0 @@
|
|||
# full profile
|
||||
|
||||
Fake configuration that contains everything I could ever need,
|
||||
used for debugging.
|
||||
Can't build a full system due to not having a filesystem / bootloader configuration,
|
||||
build as a VM (without bootloader).
|
|
@ -1,17 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
frogeye = {
|
||||
desktop.xorg = true;
|
||||
dev = {
|
||||
ansible = true;
|
||||
c = true;
|
||||
docker = true;
|
||||
fpga = true;
|
||||
perl = true;
|
||||
php = true;
|
||||
python = true;
|
||||
};
|
||||
extra = true;
|
||||
gaming = true;
|
||||
};
|
||||
}
|
10
full/os.nix
10
full/os.nix
|
@ -1,10 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../os
|
||||
./options.nix
|
||||
];
|
||||
|
||||
# Create a different disk image depending on the architecture
|
||||
networking.hostName = "${builtins.currentSystem}";
|
||||
}
|
|
@ -20,7 +20,13 @@ in
|
|||
{
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
nix = {
|
||||
package = lib.mkDefault pkgs.nixFlakes;
|
||||
settings = {
|
||||
experimental-features = [ "nix-command" "flakes" ];
|
||||
warn-dirty = false;
|
||||
};
|
||||
};
|
||||
|
||||
programs =
|
||||
let
|
||||
|
@ -429,7 +435,6 @@ in
|
|||
neofetch
|
||||
|
||||
# nix utils
|
||||
nix
|
||||
nix-diff
|
||||
nix-tree
|
||||
nix-output-monitor
|
||||
|
@ -451,6 +456,7 @@ in
|
|||
ncdu
|
||||
jdupes
|
||||
duperemove
|
||||
compsize
|
||||
|
||||
# local monitoring
|
||||
htop
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
./dev.nix
|
||||
./extra.nix
|
||||
./gaming
|
||||
./rebuild
|
||||
./ssh.nix
|
||||
./style.nix
|
||||
./usernix
|
||||
|
|
|
@ -1,11 +1,6 @@
|
|||
{ pkgs, config, lib, ... }:
|
||||
let
|
||||
nixglsrc = builtins.fetchTarball {
|
||||
url = "https://github.com/nix-community/nixGL/archive/489d6b095ab9d289fe11af0219a9ff00fe87c7c5.tar.gz";
|
||||
sha256 = "16b9jh46a02m79swsk5i5xw44738zy1i31al77mm1k8y4nxc8d9b";
|
||||
};
|
||||
nixgl = import (nixglsrc) { };
|
||||
nixGLIntelPrefix = "${nixgl.nixVulkanIntel}/bin/nixVulkanIntel ${nixgl.nixGLIntel}/bin/nixGLIntel ";
|
||||
nixGLIntelPrefix = "${pkgs.nixgl.nixVulkanIntel}/bin/nixVulkanIntel ${pkgs.nixgl.nixGLIntel}/bin/nixGLIntel ";
|
||||
wmPrefix = "${lib.optionalString config.frogeye.desktop.nixGLIntel nixGLIntelPrefix}";
|
||||
in
|
||||
{
|
||||
|
|
38
hm/rebuild/default.nix
Normal file
38
hm/rebuild/default.nix
Normal file
|
@ -0,0 +1,38 @@
|
|||
{ pkgs, config, ... }:
|
||||
let
|
||||
ulf = pkgs.writers.writePython3 "update-local-flakes" {
|
||||
} (builtins.readFile ./update-local-flakes.py);
|
||||
in
|
||||
{
|
||||
home.packages = [
|
||||
(pkgs.writeShellApplication {
|
||||
name = "rb";
|
||||
runtimeInputs = [ pkgs.brightnessctl ];
|
||||
text = ''
|
||||
verb="switch"
|
||||
if [ "$#" -ge 1 ]
|
||||
then
|
||||
verb="$1"
|
||||
shift
|
||||
fi
|
||||
nixos_flake="/etc/nixos/flake.nix"
|
||||
if [ -f "$nixos_flake" ]
|
||||
then
|
||||
sudo ${ulf} "$nixos_flake"
|
||||
if [ "$verb" = "switch" ] || [ "$verb" = "test" ]
|
||||
then
|
||||
sudo nixos-rebuild "$verb" --specialisation ${config.frogeye.polarity} "$@"
|
||||
else
|
||||
sudo nixos-rebuild "$verb" "$@"
|
||||
fi
|
||||
fi
|
||||
hm_flake="${config.xdg.configHome}/home-manager/flake.nix"
|
||||
if [ -f "$hm_flake" ]
|
||||
then
|
||||
${ulf} "$hm_flake"
|
||||
home-manager "$verb" "$@"
|
||||
fi
|
||||
'';
|
||||
})
|
||||
];
|
||||
}
|
53
hm/rebuild/update-local-flakes.py
Executable file
53
hm/rebuild/update-local-flakes.py
Executable file
|
@ -0,0 +1,53 @@
|
|||
import argparse
|
||||
import json
|
||||
import os
|
||||
import subprocess
|
||||
|
||||
GET_INPUTS_CMD = [
|
||||
"nix-instantiate",
|
||||
"--eval",
|
||||
"--json", # This parser is stupid, better provide it with pre-eaten stuff
|
||||
"--expr",
|
||||
"builtins.fromJSON (builtins.toJSON (import ./flake.nix).inputs)",
|
||||
]
|
||||
|
||||
|
||||
def process_flake(flake: str) -> None:
|
||||
# get full path
|
||||
if not os.path.isfile(flake):
|
||||
raise FileNotFoundError(f"Flake not found: {flake}")
|
||||
dir = os.path.dirname(flake)
|
||||
# import dependencies
|
||||
p = subprocess.run(GET_INPUTS_CMD, cwd=dir, stdout=subprocess.PIPE)
|
||||
deps = json.loads(p.stdout)
|
||||
p.check_returncode()
|
||||
# for each dependency
|
||||
for dep_name, dep in deps.items():
|
||||
dep_url = dep["url"]
|
||||
# if not local path, continue
|
||||
if not (
|
||||
dep_url.startswith("path:") or dep_url.startswith("git+file:")
|
||||
):
|
||||
continue
|
||||
if dep.get("flake", True):
|
||||
# get flake file corresponding
|
||||
dep_path = dep_url.split(":")[1]
|
||||
if not dep_path.startswith("/"):
|
||||
dep_path = os.path.join(dir, dep_path)
|
||||
dep_path = os.path.normpath(dep_path)
|
||||
dep_flake = os.path.join(dep_path, "flake.nix")
|
||||
# call this function with the flake file
|
||||
process_flake(dep_flake)
|
||||
# update lockfile
|
||||
cmd = ["nix", "flake", "lock", "--update-input", dep_name]
|
||||
subprocess.run(cmd, cwd=dir)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
parser = argparse.ArgumentParser(
|
||||
description="Recursively update lockfiles "
|
||||
"of flakes located on the system"
|
||||
)
|
||||
parser.add_argument("flake", help="Starting flake", default="flake.nix")
|
||||
args = parser.parse_args()
|
||||
process_flake(args.flake)
|
26
hm/style.nix
26
hm/style.nix
|
@ -1,13 +1,6 @@
|
|||
{ pkgs, config, lib, ... }:
|
||||
let
|
||||
# Currently last commit in https://github.com/danth/stylix/pull/194
|
||||
stylix = builtins.fetchTarball {
|
||||
url = "https://github.com/willemml/stylix/archive/2ed2b0086b41d582aca26e083c19c0e47c8991e3.tar.gz";
|
||||
sha256 = "1mwhpbfmw4n1lmy22s0dhbklzd8b0r7mn0mg7vbz44ac35m7kzf2";
|
||||
};
|
||||
polarityFile = "${config.xdg.stateHome}/theme_polarity";
|
||||
polarityFromFile = if builtins.pathExists polarityFile then lib.strings.fileContents polarityFile else "light";
|
||||
polarity = if config.frogeye.polarity == "dynamic" then polarityFromFile else config.frogeye.polarity;
|
||||
phases = [
|
||||
{ command = "jour"; polarity = "light"; }
|
||||
{ command = "crepuscule"; polarity = "dark"; }
|
||||
|
@ -16,10 +9,9 @@ let
|
|||
cfg = config.frogeye.desktop.phasesBrightness;
|
||||
in
|
||||
{
|
||||
imports = [ (import stylix).homeManagerModules.stylix ];
|
||||
|
||||
stylix = {
|
||||
base16Scheme = "${pkgs.base16-schemes}/share/themes/solarized-${polarity}.yaml";
|
||||
|
||||
base16Scheme = "${pkgs.base16-schemes}/share/themes/solarized-${config.frogeye.polarity}.yaml";
|
||||
image = builtins.fetchurl {
|
||||
url = "https://get.wallhere.com/photo/sunlight-abstract-minimalism-green-simple-circle-light-leaf-wave-material-line-wing-computer-wallpaper-font-close-up-macro-photography-124350.png";
|
||||
sha256 = "sha256:1zfq3f3v34i45mi72pkfqphm8kbhczsg260xjfl6dbydy91d7y93";
|
||||
|
@ -41,10 +33,6 @@ in
|
|||
};
|
||||
};
|
||||
|
||||
# Setting a custom base16 theme via nixvim:
|
||||
# - Is required so nixvim works
|
||||
# - For the rest only works on dark polarity, use the colorscheme otherwise... shrug
|
||||
programs.nixvim.colorschemes.base16.colorscheme = "solarized-${polarity}";
|
||||
|
||||
# Fix https://nix-community.github.io/home-manager/index.html#_why_do_i_get_an_error_message_about_literal_ca_desrt_dconf_literal_or_literal_dconf_service_literal
|
||||
# home.packages = [ pkgs.dconf ];
|
||||
|
@ -58,14 +46,12 @@ in
|
|||
text = (lib.optionalString cfg.enable ''
|
||||
brightnessctl set ${builtins.getAttr phase.command cfg}
|
||||
'') + ''
|
||||
echo ${phase.polarity} > ${polarityFile}
|
||||
if command -v home-manager
|
||||
switch="/nix/var/nix/profiles/system/specialisation/${phase.polarity}/bin/switch-to-configuration"
|
||||
if [ -x "$switch" ]
|
||||
then
|
||||
home-manager switch
|
||||
else
|
||||
# In two steps to get the visual changes slightly earlier
|
||||
sudo /nix/var/nix/profiles/system/specialisation/${phase.polarity}/bin/switch-to-configuration test
|
||||
sudo /nix/var/nix/profiles/system/specialisation/${phase.polarity}/bin/switch-to-configuration boot
|
||||
sudo "$switch" test
|
||||
sudo "$switch" boot
|
||||
fi
|
||||
'';
|
||||
})
|
||||
|
|
10
hm/vim.nix
10
hm/vim.nix
|
@ -1,10 +1,5 @@
|
|||
{ pkgs, lib, config, ... }:
|
||||
let
|
||||
nixvim = builtins.fetchTarball {
|
||||
url = "https://github.com/nix-community/nixvim/archive/c96d7b46d05a78e695ed1c725d1596b65509b4f9.tar.gz";
|
||||
# 24.05 Anythin after this commit works
|
||||
sha256 = "0brzl3k11qjy81wvs1i8ngbk4kkxild9ps3ammnbr912ldvq9nac";
|
||||
};
|
||||
vim-shot-f = pkgs.vimUtils.buildVimPlugin {
|
||||
pname = "vim-shot-f";
|
||||
version = "2016-02-05";
|
||||
|
@ -29,10 +24,13 @@ let
|
|||
};
|
||||
in
|
||||
{
|
||||
imports = [ (import nixvim).homeManagerModules.nixvim ];
|
||||
|
||||
programs.nixvim = {
|
||||
enable = true;
|
||||
# Setting a custom base16 theme via nixvim is required so feline works, and
|
||||
# because stylix makes a config that otherwise only works with dark
|
||||
# polarity.
|
||||
colorschemes.base16.colorscheme = "solarized-${config.frogeye.polarity}";
|
||||
options = {
|
||||
# From https://www.hillelwayne.com/post/intermediate-vim/
|
||||
title = true;
|
||||
|
|
|
@ -2,6 +2,9 @@
|
|||
#! nix-shell -i bash
|
||||
#! nix-shell -p bash nixos-install-tools
|
||||
|
||||
echo FIXME Not flakes ready
|
||||
exit 1
|
||||
|
||||
set -euo pipefail
|
||||
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
|
||||
|
||||
|
@ -91,6 +94,19 @@ sudo nixos-generate-config --no-filesystems --root "$mountpoint"
|
|||
# Plug system configuration into this git repo
|
||||
sudo mkdir -p "${mountpoint}/etc/nixos"
|
||||
echo "{ ... }: { imports = [ ./hardware-configuration.nix ${nixos_config} ]; }" | sudo tee "${mountpoint}/etc/nixos/configuration.nix" > /dev/null
|
||||
# EXAMPLE
|
||||
# {
|
||||
# description = "curacao system config";
|
||||
#
|
||||
# inputs.dotfiles.url = "git+file:/home/geoffrey/.config/gdotfiles";
|
||||
#
|
||||
# outputs = { self, dotfiles, ... }:
|
||||
# {
|
||||
# nixosConfigurations.curacao = dotfiles.nixosConfigurations.curacao.extendModules {
|
||||
# modules = [ ./hardware-configuration.nix ];
|
||||
# };
|
||||
# };
|
||||
# }
|
||||
# Everything there should be covered by (and conflicts with) the repo anyways.
|
||||
|
||||
# Install NixOS! Or create a new generation.
|
||||
|
|
|
@ -5,9 +5,9 @@
|
|||
gaming = lib.mkEnableOption "Games";
|
||||
userNix = lib.mkEnableOption "Nix is \"installed\" in ~/.nix";
|
||||
polarity = lib.mkOption {
|
||||
default = "dynamic";
|
||||
default = "light";
|
||||
description = "Whether to use light theme or dark theme.";
|
||||
type = lib.types.enum [ "dynamic" "light" "dark" ];
|
||||
type = lib.types.enum [ "light" "dark" ];
|
||||
};
|
||||
desktop = {
|
||||
xorg = lib.mkEnableOption "Enable X11 support";
|
||||
|
|
|
@ -29,7 +29,10 @@
|
|||
];
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
nix.settings = {
|
||||
experimental-features = [ "nix-command" "flakes" ];
|
||||
warn-dirty = false;
|
||||
};
|
||||
|
||||
programs = {
|
||||
adb.enable = true;
|
||||
|
|
|
@ -9,10 +9,5 @@
|
|||
./gaming
|
||||
./geoffrey.nix
|
||||
./wireless.nix
|
||||
"${builtins.fetchTarball {
|
||||
url = "https://github.com/nix-community/disko/archive/3cb78c93e6a02f494aaf6aeb37481c27a2e2ee22.tar.gz";
|
||||
sha256 = "0slkd86c7viv8ping6wizhab6iwxz0bn9fxvzrscz0r745d8iaca";
|
||||
}
|
||||
}/module.nix"
|
||||
];
|
||||
}
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{ pkgs, lib, config, ... }:
|
||||
{
|
||||
config = lib.mkIf config.frogeye.gaming {
|
||||
config = lib.mkIf config.frogeye.gaming
|
||||
{
|
||||
programs.steam.enable = true;
|
||||
hardware.opengl.driSupport32Bit = true; # Enables support for 32bit libs that steam uses
|
||||
};
|
||||
|
|
|
@ -1,9 +1,5 @@
|
|||
{ pkgs, lib, config, ... }:
|
||||
{
|
||||
imports = [
|
||||
<home-manager/nixos>
|
||||
];
|
||||
|
||||
users.users.root.initialHashedPassword = "$y$j9T$e64bjL7iyVlniEKwKbM9g0$cCn74za0r6L9QMO20Fdxz3/SX0yvhz3Xd6.2BhtbRL1"; # Not a real password
|
||||
|
||||
users.users.geoffrey = {
|
||||
|
|
|
@ -3,7 +3,6 @@
|
|||
# wireless support via wpa_supplicant
|
||||
networking.wireless = {
|
||||
enable = true;
|
||||
networks = builtins.fromJSON (builtins.readFile ./wireless/networks.json); # If this file doesn't exist, run ./wireless/import.py
|
||||
extraConfig = ''
|
||||
country=NL
|
||||
'';
|
||||
|
|
4
os/wireless/.gitignore
vendored
4
os/wireless/.gitignore
vendored
|
@ -1,2 +1,2 @@
|
|||
networks.json
|
||||
networks.env
|
||||
wireless_networks.json
|
||||
wireless_networks.env
|
||||
|
|
|
@ -11,6 +11,7 @@ Exports Wi-Fi networks configuration stored in pass into a format readable by Ni
|
|||
# url = "https://letsencrypt.org/certs/isrgrootx1.pem";
|
||||
# sha256 = "sha256:1la36n2f31j9s03v847ig6ny9lr875q3g7smnq33dcsmf2i5gd92";
|
||||
# }
|
||||
# TODO Very ugly, can probably do better
|
||||
|
||||
import hashlib
|
||||
import json
|
||||
|
@ -157,10 +158,14 @@ for path in list_networks():
|
|||
for suffix in suffixes:
|
||||
networks[ssid + suffix] = network
|
||||
|
||||
with open("networks.json", "w") as fd:
|
||||
with open("wireless_networks.json", "w") as fd:
|
||||
json.dump(networks, fd, indent=4)
|
||||
|
||||
with open("networks.env", "w") as fd:
|
||||
with open("wireless_networks.env", "w") as fd:
|
||||
if SEPARATE_PASSWORDS:
|
||||
for k, v in Password.vars().items():
|
||||
print(f"{k}={v}", file=fd)
|
||||
|
||||
print("Now, execute:")
|
||||
print("sudo mv -f wireless_networks.* /etc/keys")
|
||||
print("sudo nixos-rebuild switch")
|
||||
|
|
|
@ -1,9 +1,5 @@
|
|||
{ pkgs, config, ... }:
|
||||
{
|
||||
imports = [
|
||||
<nixos-hardware/pine64/pinebook-pro>
|
||||
];
|
||||
|
||||
boot = {
|
||||
# nixos-hardware use latest kernel by default. It has been set a while ago, we maybe don't need it anymore?
|
||||
kernelPackages = pkgs.linuxPackages;
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../os
|
||||
./hardware.nix
|
||||
./dk.nix
|
||||
./options.nix
|
||||
|
|
|
@ -1,2 +0,0 @@
|
|||
{ ... } @ args:
|
||||
import ../dk/single_uefi_btrfs.nix (args // { id = "mmc-SN32G_0xfb19ae99"; name = "pindakaas_sd"; })
|
|
@ -1,11 +0,0 @@
|
|||
{ pkgs, config, ... }:
|
||||
{
|
||||
imports = [
|
||||
../os
|
||||
../pindakaas/options.nix
|
||||
../pindakaas/hardware.nix
|
||||
./dk.nix
|
||||
];
|
||||
|
||||
networking.hostName = "pindakaas_sd";
|
||||
}
|
1
sprinkles/README.md
Normal file
1
sprinkles/README.md
Normal file
|
@ -0,0 +1 @@
|
|||
FIXME Make this work with flakes
|
Loading…
Reference in a new issue