This commit is contained in:
CherryKitten 2024-03-24 19:02:29 +01:00
parent 9233d64ef3
commit 001f641a7f
Signed by: sammy
GPG key ID: 98D8F75FB0658276
16 changed files with 236 additions and 226 deletions

View file

@ -9,18 +9,29 @@
};
};
outputs = inputs @ {
self,
nixpkgs,
nixpkgs-unstable,
home-manager,
...
}: let
outputs =
inputs @ { self
, nixpkgs
, nixpkgs-unstable
, home-manager
, ...
}:
let
inherit (self) outputs;
systems = [
"aarch64-linux"
"i686-linux"
"x86_64-linux"
"aarch64-darwin"
"x86_64-darwin"
];
forEachSystem = f: lib.genAttrs systems (system: f);
forAllSystems = lib.genAttrs systems;
lib = nixpkgs.lib // home-manager.lib;
mkHost = {
hostname,
user ? "sammy",
mkHost =
{ hostname
, user ? "sammy"
,
}: {
imports = [
./hosts/${hostname}/configuration.nix
@ -33,9 +44,10 @@
allowLocalDeployment = true;
};
};
in {
in
{
inherit lib;
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.alejandra;
formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.nixpkgs-fmt);
colmena = {
meta = {
description = "All my NixoS machines";

View file

@ -1,11 +1,10 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page, on
# https://search.nixos.org/options and in the NixOS manual (`nixos-help`).
{
config,
lib,
pkgs,
...
{ config
, lib
, pkgs
, ...
}: {
imports = [
# Include the results of the hardware scan.

View file

@ -1,12 +1,11 @@
# 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,
...
{ config
, lib
, pkgs
, modulesPath
, ...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")

View file

@ -1,8 +1,7 @@
{
config,
pkgs,
lib,
...
{ config
, pkgs
, lib
, ...
}: {
imports = [
# Include the results of the hardware scan.

View file

@ -1,11 +1,10 @@
# 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,
...
{ config
, lib
, pkgs
, ...
}: {
boot.initrd.availableKernelModules = [ "ahci" "nvme" ];
boot.initrd.kernelModules = [ ];

View file

@ -1,8 +1,7 @@
{
config,
lib,
pkgs,
...
{ config
, lib
, pkgs
, ...
}: {
users.users.admin = {
isNormalUser = true;

View file

@ -1,11 +1,12 @@
{
pkgs,
config,
lib,
...
}: let
{ pkgs
, config
, lib
, ...
}:
let
cfg = config.cherrykitten;
in {
in
{
options.cherrykitten = { };
config = { };

View file

@ -1,8 +1,7 @@
{
pkgs,
config,
lib,
...
{ pkgs
, config
, lib
, ...
}: {
imports = [ ./fish ./nvim ];
home.packages = with pkgs; [

View file

@ -1,8 +1,7 @@
{
pkgs,
config,
lib,
...
{ pkgs
, config
, lib
, ...
}: {
programs.fish = {
enable = true;

View file

@ -1,13 +1,14 @@
{
config,
pkgs,
inputs,
...
{ config
, pkgs
, inputs
, ...
}: {
programs.neovim = let
programs.neovim =
let
toLua = str: "lua << EOF\n${str}\nEOF\n";
toLuaFile = file: "lua << EOF\n${builtins.readFile file}\nEOF\n";
in {
in
{
enable = true;
viAlias = true;

View file

@ -1,11 +1,12 @@
{
lib,
config,
pkgs,
...
}: let
{ lib
, config
, pkgs
, ...
}:
let
cfg = config.cherrykitten.common;
in {
in
{
options.cherrykitten.common = {
test = lib.mkOption {
type = lib.types.str;

View file

@ -1,11 +1,12 @@
{
pkgs,
config,
lib,
...
}: let
{ pkgs
, config
, lib
, ...
}:
let
cfg = config.cherrykitten.graphical;
in {
in
{
options.cherrykitten.graphical = {
enable = lib.mkEnableOption (lib.mdDoc "graphical stuffs");
};

View file

@ -1,11 +1,12 @@
{
pkgs,
config,
lib,
...
}: let
{ pkgs
, config
, lib
, ...
}:
let
cfg = config.cherrykitten.users;
in {
in
{
options.cherrykitten.users = {
sammy.enable = lib.mkEnableOption "sammy" // { default = true; };
};