1
0
Files
nix-shared/flake.nix

91 lines
2.1 KiB
Nix
Raw Normal View History

2025-06-23 17:44:56 -07:00
{
description = "Timo's Shared Nix Modules";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
};
2025-09-19 22:17:25 -07:00
outputs = { self, nixpkgs, ... }: {
# Set up formatter.
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixpkgs-fmt;
2025-06-25 23:35:24 -07:00
Add homeManagerModules.claude for Claude Code configuration management This commit introduces a new home-manager module that provides declarative configuration management for Claude Code, Anthropic's official CLI tool. The module follows the established pattern used by other home-manager modules in this flake (default, private, macos, develop) and enables users to deploy custom Claude Code slash commands and configuration files to ~/.claude/. Changes included: 1. Created home/claude/config.nix module: - Defines a new home-manager module for Claude Code configuration - Uses home.file to deploy command files from the Nix store to ~/.claude/ - Currently deploys two custom slash commands to ~/.claude/commands/ 2. Added two custom slash commands: - commit.md: Automates git commit creation by reading staged diffs and generating comprehensive commit messages - go-plan.md: Writes detailed implementation plans to PLAN.md before starting work, supporting the planning workflow 3. Registered homeManagerModules.claude in flake.nix: - Added as a new, independent module group that can be imported separately - Positioned after the develop module for logical organization - Can be enabled by importing inputs.nix-shared.homeManagerModules.claude 4. Enhanced flake.nix documentation: - Added descriptive comments for all nixosModules and homeManagerModules - Clarifies the purpose of each module group (e.g., "Linux specific system configuration", "Add private homelab and cloud host aliases") - Improves maintainability and makes the flake structure self-documenting The module structure supports easy extension - additional slash commands or configuration files can be added by placing them in home/claude/config/ and adding corresponding home.file entries in config.nix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-13 23:08:01 -08:00
# Global all-hosts configuration
2025-09-19 22:17:25 -07:00
nixosModules.default = { ... }: {
imports = [
./system/default/editor.nix
./system/default/nix.nix
./system/default/packages.nix
./system/default/prompt.nix
./system/default/ssh-authorized-keys.nix
2025-09-19 22:17:25 -07:00
];
};
Add homeManagerModules.claude for Claude Code configuration management This commit introduces a new home-manager module that provides declarative configuration management for Claude Code, Anthropic's official CLI tool. The module follows the established pattern used by other home-manager modules in this flake (default, private, macos, develop) and enables users to deploy custom Claude Code slash commands and configuration files to ~/.claude/. Changes included: 1. Created home/claude/config.nix module: - Defines a new home-manager module for Claude Code configuration - Uses home.file to deploy command files from the Nix store to ~/.claude/ - Currently deploys two custom slash commands to ~/.claude/commands/ 2. Added two custom slash commands: - commit.md: Automates git commit creation by reading staged diffs and generating comprehensive commit messages - go-plan.md: Writes detailed implementation plans to PLAN.md before starting work, supporting the planning workflow 3. Registered homeManagerModules.claude in flake.nix: - Added as a new, independent module group that can be imported separately - Positioned after the develop module for logical organization - Can be enabled by importing inputs.nix-shared.homeManagerModules.claude 4. Enhanced flake.nix documentation: - Added descriptive comments for all nixosModules and homeManagerModules - Clarifies the purpose of each module group (e.g., "Linux specific system configuration", "Add private homelab and cloud host aliases") - Improves maintainability and makes the flake structure self-documenting The module structure supports easy extension - additional slash commands or configuration files can be added by placing them in home/claude/config/ and adding corresponding home.file entries in config.nix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-13 23:08:01 -08:00
# Linux specific system configuration
2025-09-19 22:17:25 -07:00
nixosModules.linux = { ... }: {
imports = [
2025-09-22 08:45:27 -07:00
./system/linux/i18n.nix
2025-11-04 18:50:32 -08:00
./system/linux/openssh.nix
2025-09-19 22:17:25 -07:00
./system/linux/system.nix
2025-11-04 18:50:32 -08:00
./system/linux/user-tb.nix
2025-09-19 22:17:25 -07:00
];
};
2025-06-23 17:44:56 -07:00
Add homeManagerModules.claude for Claude Code configuration management This commit introduces a new home-manager module that provides declarative configuration management for Claude Code, Anthropic's official CLI tool. The module follows the established pattern used by other home-manager modules in this flake (default, private, macos, develop) and enables users to deploy custom Claude Code slash commands and configuration files to ~/.claude/. Changes included: 1. Created home/claude/config.nix module: - Defines a new home-manager module for Claude Code configuration - Uses home.file to deploy command files from the Nix store to ~/.claude/ - Currently deploys two custom slash commands to ~/.claude/commands/ 2. Added two custom slash commands: - commit.md: Automates git commit creation by reading staged diffs and generating comprehensive commit messages - go-plan.md: Writes detailed implementation plans to PLAN.md before starting work, supporting the planning workflow 3. Registered homeManagerModules.claude in flake.nix: - Added as a new, independent module group that can be imported separately - Positioned after the develop module for logical organization - Can be enabled by importing inputs.nix-shared.homeManagerModules.claude 4. Enhanced flake.nix documentation: - Added descriptive comments for all nixosModules and homeManagerModules - Clarifies the purpose of each module group (e.g., "Linux specific system configuration", "Add private homelab and cloud host aliases") - Improves maintainability and makes the flake structure self-documenting The module structure supports easy extension - additional slash commands or configuration files can be added by placing them in home/claude/config/ and adding corresponding home.file entries in config.nix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-13 23:08:01 -08:00
# MacOS specific system configuration
2025-09-19 22:17:25 -07:00
nixosModules.macos = { ... }: {
imports = [
2025-09-21 09:19:07 -07:00
./system/macos/environment.nix
2025-09-19 22:17:25 -07:00
./system/macos/fonts.nix
2025-09-21 17:00:10 -07:00
./system/macos/hotkeys.nix
./system/macos/nix.nix
2025-09-21 09:19:07 -07:00
./system/macos/system.nix
2025-09-21 16:03:27 -07:00
./system/macos/yabai.nix
2025-09-19 22:17:25 -07:00
];
};
2025-08-11 08:17:44 -07:00
Add homeManagerModules.claude for Claude Code configuration management This commit introduces a new home-manager module that provides declarative configuration management for Claude Code, Anthropic's official CLI tool. The module follows the established pattern used by other home-manager modules in this flake (default, private, macos, develop) and enables users to deploy custom Claude Code slash commands and configuration files to ~/.claude/. Changes included: 1. Created home/claude/config.nix module: - Defines a new home-manager module for Claude Code configuration - Uses home.file to deploy command files from the Nix store to ~/.claude/ - Currently deploys two custom slash commands to ~/.claude/commands/ 2. Added two custom slash commands: - commit.md: Automates git commit creation by reading staged diffs and generating comprehensive commit messages - go-plan.md: Writes detailed implementation plans to PLAN.md before starting work, supporting the planning workflow 3. Registered homeManagerModules.claude in flake.nix: - Added as a new, independent module group that can be imported separately - Positioned after the develop module for logical organization - Can be enabled by importing inputs.nix-shared.homeManagerModules.claude 4. Enhanced flake.nix documentation: - Added descriptive comments for all nixosModules and homeManagerModules - Clarifies the purpose of each module group (e.g., "Linux specific system configuration", "Add private homelab and cloud host aliases") - Improves maintainability and makes the flake structure self-documenting The module structure supports easy extension - additional slash commands or configuration files can be added by placing them in home/claude/config/ and adding corresponding home.file entries in config.nix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-13 23:08:01 -08:00
# Tools on all development machines
nixosModules.develop = { ... }: {
imports = [
./system/develop/packages.nix
];
};
2025-09-19 22:17:25 -07:00
# Home Manager Modules
homeManagerModules.default = { ... }: {
imports = [
./home/default/bash.nix
./home/default/basic.nix
./home/default/direnv.nix
./home/default/git.nix
];
};
2025-06-23 17:44:56 -07:00
Add homeManagerModules.claude for Claude Code configuration management This commit introduces a new home-manager module that provides declarative configuration management for Claude Code, Anthropic's official CLI tool. The module follows the established pattern used by other home-manager modules in this flake (default, private, macos, develop) and enables users to deploy custom Claude Code slash commands and configuration files to ~/.claude/. Changes included: 1. Created home/claude/config.nix module: - Defines a new home-manager module for Claude Code configuration - Uses home.file to deploy command files from the Nix store to ~/.claude/ - Currently deploys two custom slash commands to ~/.claude/commands/ 2. Added two custom slash commands: - commit.md: Automates git commit creation by reading staged diffs and generating comprehensive commit messages - go-plan.md: Writes detailed implementation plans to PLAN.md before starting work, supporting the planning workflow 3. Registered homeManagerModules.claude in flake.nix: - Added as a new, independent module group that can be imported separately - Positioned after the develop module for logical organization - Can be enabled by importing inputs.nix-shared.homeManagerModules.claude 4. Enhanced flake.nix documentation: - Added descriptive comments for all nixosModules and homeManagerModules - Clarifies the purpose of each module group (e.g., "Linux specific system configuration", "Add private homelab and cloud host aliases") - Improves maintainability and makes the flake structure self-documenting The module structure supports easy extension - additional slash commands or configuration files can be added by placing them in home/claude/config/ and adding corresponding home.file entries in config.nix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-13 23:08:01 -08:00
# Add private homelab and cloud host aliases
homeManagerModules.private = { ... }: {
imports = [
./home/private/ssh-hosts.nix
];
};
Add homeManagerModules.claude for Claude Code configuration management This commit introduces a new home-manager module that provides declarative configuration management for Claude Code, Anthropic's official CLI tool. The module follows the established pattern used by other home-manager modules in this flake (default, private, macos, develop) and enables users to deploy custom Claude Code slash commands and configuration files to ~/.claude/. Changes included: 1. Created home/claude/config.nix module: - Defines a new home-manager module for Claude Code configuration - Uses home.file to deploy command files from the Nix store to ~/.claude/ - Currently deploys two custom slash commands to ~/.claude/commands/ 2. Added two custom slash commands: - commit.md: Automates git commit creation by reading staged diffs and generating comprehensive commit messages - go-plan.md: Writes detailed implementation plans to PLAN.md before starting work, supporting the planning workflow 3. Registered homeManagerModules.claude in flake.nix: - Added as a new, independent module group that can be imported separately - Positioned after the develop module for logical organization - Can be enabled by importing inputs.nix-shared.homeManagerModules.claude 4. Enhanced flake.nix documentation: - Added descriptive comments for all nixosModules and homeManagerModules - Clarifies the purpose of each module group (e.g., "Linux specific system configuration", "Add private homelab and cloud host aliases") - Improves maintainability and makes the flake structure self-documenting The module structure supports easy extension - additional slash commands or configuration files can be added by placing them in home/claude/config/ and adding corresponding home.file entries in config.nix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-13 23:08:01 -08:00
# MacOS specific home configuration
2025-09-21 19:04:45 -07:00
homeManagerModules.macos = { ... }: {
imports = [
./home/macos/home.nix
];
};
Add homeManagerModules.claude for Claude Code configuration management This commit introduces a new home-manager module that provides declarative configuration management for Claude Code, Anthropic's official CLI tool. The module follows the established pattern used by other home-manager modules in this flake (default, private, macos, develop) and enables users to deploy custom Claude Code slash commands and configuration files to ~/.claude/. Changes included: 1. Created home/claude/config.nix module: - Defines a new home-manager module for Claude Code configuration - Uses home.file to deploy command files from the Nix store to ~/.claude/ - Currently deploys two custom slash commands to ~/.claude/commands/ 2. Added two custom slash commands: - commit.md: Automates git commit creation by reading staged diffs and generating comprehensive commit messages - go-plan.md: Writes detailed implementation plans to PLAN.md before starting work, supporting the planning workflow 3. Registered homeManagerModules.claude in flake.nix: - Added as a new, independent module group that can be imported separately - Positioned after the develop module for logical organization - Can be enabled by importing inputs.nix-shared.homeManagerModules.claude 4. Enhanced flake.nix documentation: - Added descriptive comments for all nixosModules and homeManagerModules - Clarifies the purpose of each module group (e.g., "Linux specific system configuration", "Add private homelab and cloud host aliases") - Improves maintainability and makes the flake structure self-documenting The module structure supports easy extension - additional slash commands or configuration files can be added by placing them in home/claude/config/ and adding corresponding home.file entries in config.nix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-13 23:08:01 -08:00
# Emacs Configuration
2025-09-19 22:17:25 -07:00
homeManagerModules.develop = { ... }: {
imports = [
./home/develop/emacs.nix
];
2025-06-23 17:44:56 -07:00
};
Add homeManagerModules.claude for Claude Code configuration management This commit introduces a new home-manager module that provides declarative configuration management for Claude Code, Anthropic's official CLI tool. The module follows the established pattern used by other home-manager modules in this flake (default, private, macos, develop) and enables users to deploy custom Claude Code slash commands and configuration files to ~/.claude/. Changes included: 1. Created home/claude/config.nix module: - Defines a new home-manager module for Claude Code configuration - Uses home.file to deploy command files from the Nix store to ~/.claude/ - Currently deploys two custom slash commands to ~/.claude/commands/ 2. Added two custom slash commands: - commit.md: Automates git commit creation by reading staged diffs and generating comprehensive commit messages - go-plan.md: Writes detailed implementation plans to PLAN.md before starting work, supporting the planning workflow 3. Registered homeManagerModules.claude in flake.nix: - Added as a new, independent module group that can be imported separately - Positioned after the develop module for logical organization - Can be enabled by importing inputs.nix-shared.homeManagerModules.claude 4. Enhanced flake.nix documentation: - Added descriptive comments for all nixosModules and homeManagerModules - Clarifies the purpose of each module group (e.g., "Linux specific system configuration", "Add private homelab and cloud host aliases") - Improves maintainability and makes the flake structure self-documenting The module structure supports easy extension - additional slash commands or configuration files can be added by placing them in home/claude/config/ and adding corresponding home.file entries in config.nix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-13 23:08:01 -08:00
# Claude Code configuration
homeManagerModules.claude = { ... }: {
imports = [
./home/claude/config.nix
];
};
2025-09-19 22:17:25 -07:00
};
2025-06-23 17:44:56 -07:00
}