Skip to content

Setup: Prerequisites and Workspace Configuration

This page walks through everything you need before running the examples in this course.

Prerequisites

Claude Code must be installed and authenticated.

Check your installation:

Terminal window
claude --version

If the command is not found, install Claude Code from claude.ai/code and follow the authentication steps before continuing.

Where skills can live

Claude Code looks for skills in four locations, checked in this order. A skill found earlier in the list takes precedence over a skill with the same name found later.

ScopePathWho it applies to
EnterpriseSet by your organization’s admin configAll users in the organization
Personal~/.claude/skills/You, across all projects
Project<project-root>/.claude/skills/Anyone who opens that project
PluginProvided by a Claude Code pluginUsers who have the plugin installed

For this course, you will use the personal scope (~/.claude/skills/) for most examples so that the skills are available regardless of which directory you are in.

Install the hello-skill example

Manual installation

Terminal window
# Create the personal skills directory if it does not exist
mkdir -p ~/.claude/skills
# Copy the hello-skill example
cp -r examples/hello-skill ~/.claude/skills/

Using the install script

The scripts/install-examples.sh script handles validation and copying:

Terminal window
bash scripts/install-examples.sh examples/hello-skill personal

The script will confirm the installation path and print the command to invoke the skill.

Confirm a skill is loaded

Open Claude Code in interactive mode:

Terminal window
claude

Then type:

what skills are available?

Claude will list the skills it found at startup, including hello-skill if the installation succeeded. You can also invoke it directly:

/hello-skill

Headless mode basics

Headless mode (claude -p) runs Claude Code non-interactively — useful for scripts, CI pipelines, and chaining commands. Claude processes the prompt, writes output to stdout, and exits.

Terminal window
claude -p "summarize the last 5 git commits"

Use headless mode when you want to automate a task or integrate Claude into a shell pipeline. Use interactive mode when you are exploring, iterating, or want to have a back-and-forth conversation.

Invoking skills in headless mode

There are three common patterns:

Pattern 1 — Invoke by name:

Terminal window
claude -p "/hello-skill"

Pattern 2 — Invoke with an argument:

Terminal window
claude -p "/hello-skill World"

Pattern 3 — Pipe input as context:

Terminal window
echo "some context or data" | claude -p "/hello-skill"

The piped content arrives as stdin. Skills can read it via the ${stdin} placeholder or by referencing the input in their instructions. This is useful when the skill needs to process a file, a command’s output, or a block of text you have already prepared.

Next steps

With your environment set up and hello-skill confirmed working, continue to the first section:

  • 01-basic — writing your first real skill from scratch