Claude Skills
CollectionsCompareWorkflowsNominate
Sign inSign up
© 2026 Curated Agent Skills·Learn more about Agent Skills
Back to repository

nushell-fundamentals

verified

This skill should be used when the user asks to "write a Nushell script", "create a Nushell command", "understand Nushell syntax", "work with Nushell pipelines", "use closures in Nushell", "create a Nushell module", "define an overlay", "understand Nushell types", or mentions core Nushell concepts like pipelines, closures, modules, overlays, custom commands, or type annotations.

View on GitHub

Marketplace

nushell-marketplace

danielbodnar/nushell-dev

Plugin

nushell-dev

development

Repository

danielbodnar/nushell-dev
1stars

plugins/nushell-dev/skills/nushell-fundamentals/SKILL.md

Last Verified

February 1, 2026

Install Skill

Select agents to install to:

Scope:
npx add-skill https://github.com/danielbodnar/nushell-dev/blob/main/plugins/nushell-dev/skills/nushell-fundamentals/SKILL.md -a claude-code --skill nushell-fundamentals

Installation paths:

Claude
.claude/skills/nushell-fundamentals/
Powered by add-skill CLI

Instructions

# Nushell Fundamentals

Comprehensive reference for core Nushell language patterns, syntax, and best practices. Nushell treats data as structured tables rather than text streams, enabling type-safe pipelines and powerful data manipulation.

## Core Philosophy

Nushell follows the Unix philosophy with modern enhancements:
- **Everything is data** - Commands return structured tables, records, and lists
- **Pipelines are typed** - Data flows with known shapes between commands
- **Errors are values** - Explicit error handling, not silent failures
- **Help is built-in** - Every command has discoverable documentation

## Data Types

### Primitive Types

| Type | Example | Description |
|------|---------|-------------|
| `int` | `42`, `-17` | 64-bit signed integers |
| `float` | `3.14`, `1e-5` | 64-bit floating point |
| `string` | `"hello"`, `'world'` | UTF-8 text |
| `bool` | `true`, `false` | Boolean values |
| `duration` | `5min`, `2hr`, `1day` | Time durations |
| `filesize` | `10kb`, `1gb`, `512mb` | File sizes |
| `date` | `2024-01-15` | Date/datetime |
| `nothing` | `null` | Absence of value |
| `binary` | `0x[FF 00 AB]` | Raw bytes |

### Structured Types

| Type | Syntax | Description |
|------|--------|-------------|
| `list` | `[1, 2, 3]` | Ordered collection |
| `record` | `{name: "foo", value: 42}` | Key-value mapping |
| `table` | `[[a, b]; [1, 2], [3, 4]]` | List of records |
| `closure` | `{\|x\| $x + 1}` | Anonymous function |

### Type Annotations

Annotate function parameters and return types for safety:

```nushell
def greet [name: string] -> string {
    $"Hello, ($name)!"
}

def add [a: int, b: int] -> int {
    $a + $b
}

# Optional parameters with defaults
def connect [host: string, --port: int = 8080] {
    # ...
}

# Rest parameters
def sum [...nums: int] -> int {
    $nums | math sum
}
```

## Pipelines

### Basic Pipeline Flow

```nushell
# Data flows left to right through pipes
ls | where size > 1mb | sort-by modified | first 5

# Each stage r

Validation Details

Front Matter
Required Fields
Valid Name Format
Valid Description
Has Sections
Allowed Tools
Instruction Length:
7395 chars