An opinionated NixOS-WSL setup where AI tools are system packages, not ad-hoc installs.
Why | Features | Quick Start | What's Included | Architecture
Your dev environment shouldn't break. Your AI tools shouldn't be scattered across npm, pip, and random binaries.
npm install, pip install, curl | bash --> replaced by one flake.
Because environments drift. And drift kills focus.
agentic-os treats AI coding assistants as first-class system dependencies — declarative, reproducible, and update-controlled.
# New PC? One command. Same environment.
sudo nixos-rebuild switch --flake .#wslagentic-os is not a dotfiles repo. It's an operating system profile.
- 5 AI coding agents built into the system
- Controlled updates via
nix flake update llm-agents - Custom derivations for tools not in nixpkgs (e.g., Docker cagent)
- Same config = same environment, guaranteed
- Instant rollback:
nixos-rebuild switch --rollback - Generations history for full traceability
- Config lives on Windows filesystem — survives WSL resets
- Native Docker daemon — no Docker Desktop license needed
- VS Code Remote compatible via nix-ld
- Windows 11 + WSL 2.4.4+
- NixOS-WSL installed
# Clone to Windows filesystem (resilient location)
cd /mnt/c/Users/<your-user>
git clone https://github.com/iacker/agentic-os.git
cd agentic-os
# Build your AI-native OS
sudo nixos-rebuild switch --flake .#wsl
# Reconnect for docker group
exit# Proof: AI tools are now system binaries
which claude gemini codex opencode cagent| Command | Provider | Source |
|---|---|---|
claude |
Anthropic | llm-agents flake |
gemini |
llm-agents flake | |
opencode |
SST | llm-agents flake |
codex |
OpenAI | nixpkgs |
cagent |
Docker | custom derivation |
| Category | Tools |
|---|---|
| Navigation | fzf, ripgrep, fd, lsd, bat |
| Data | jq, yq |
| Network | curl, wget, htop |
| Git | git, gh, lazygit |
| Dev | python312, nodejs_22 |
Pre-configured with LSP servers and formatters:
| LSP Servers | Languages |
|---|---|
| nil | Nix |
| lua-language-server | Lua |
| typescript-language-server | TypeScript/JavaScript |
| bash-language-server | Bash |
| yaml-language-server | YAML |
| pyright | Python |
| gopls | Go |
| rust-analyzer | Rust |
| terraform-ls | Terraform |
| marksman | Markdown |
| Formatters/Linters | |
|---|---|
| stylua | Lua |
| shellcheck, shfmt | Shell |
| black | Python |
| alejandra | Nix |
LazyVim starter auto-installs on first rebuild.
- Native daemon (no Docker Desktop)
- Auto-prune enabled
- Starts on boot
nix-ld configured with common libraries for seamless VS Code Remote-WSL support.
flake.nix # Entry point + inputs
├── hosts/wsl.nix # WSL system configuration
└── modules/
├── ai-cli.nix # AI agents as system packages
├── docker.nix # Docker daemon with auto-prune
├── lazyvim.nix # Neovim + 10 LSP servers + formatters
├── tools.nix # CLI tools (git, fzf, ripgrep...)
└── vscode.nix # nix-ld for VS Code Remote
Each module is a reusable, declarative system capability.
# Update AI tools only
nix flake update llm-agents
sudo nixos-rebuild switch --flake .#wsl
# Update everything
nix flake update
sudo nixos-rebuild switch --flake .#wsl
# Something broke? Rollback instantly
sudo nixos-rebuild switch --rollback
# List all generations
sudo nix-env -p /nix/var/nix/profiles/system --list-generations
# Test a package without installing
nix-shell -p <package>This repo includes a CLAUDE.md file — instructions for AI assistants working on this codebase.
This repo is AI-readable by design.
It defines project structure, essential commands, and conventions so Claude Code (and other AI tools) can collaborate effectively on your system configuration.
Everything is modular by design. You never touch the base system.
# Edit the relevant module
nvim modules/tools.nix
# Add your package to environment.systemPackages
# Apply
git add .
sudo nixos-rebuild switch --flake .#wsl- Create
modules/mymodule.nix - Import it in
hosts/wsl.nix - Rebuild
MIT
Stop configuring. Start building.
