Skip to content
Back to skills

Nix Patterns

ASecurity

NixOS module patterns. Use when creating or editing NixOS/home-manager modules, adding packages, or configuring programs.

  • 470 stars
  • 0 votes
  • 0 copies
  • 14 views
  • Added February 7, 2026
devops

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned February 12, 2026

npx -y skills add aiskillstore/marketplace --skill nix-patterns --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Nix Patterns?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Nix Patterns
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/aiskillstore-nix-patterns/badge)](https://www.skillsdirectory.com/skills/aiskillstore-nix-patterns)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: nix-patterns
description: NixOS module patterns. Use when creating or editing NixOS/home-manager modules, adding packages, or configuring programs.
---

# NixOS Module Patterns

## Directory structure
- `modules/home/*.nix` - Home-manager modules (user packages, dotfiles)
- `modules/nixos/*.nix` - NixOS modules (system services)
- `hosts/*/` - Machine-specific configuration
- `home/default.nix` - Main home-manager entry point

## Adding packages
```nix
home.packages = with pkgs; [
  package-name
] ++ lib.optionals (stdenv.hostPlatform.system == "x86_64-linux") [
  x86-only-package
];
```

## Creating a module
```nix
{ pkgs, ... }:
{
  home.packages = with pkgs; [ mypackage ];
  xdg.configFile."app/config.json".text = builtins.toJSON { setting = "value"; };
}
```

Import in `home/default.nix`:
```nix
imports = [ ../modules/home/mymodule.nix ];
```

Files in this skill

  • SKILL.md869 B
  • skill-report.json8.2 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.