$npx -y skills add opendatahub-io/ai-helpers --skill hello-world-echoHello world plugin implementation
| 1 | ## Name |
| 2 | odh-ai-helpers:hello-world-echo |
| 3 | |
| 4 | ## Synopsis |
| 5 | ``` |
| 6 | /hello-world:echo [name] |
| 7 | ``` |
| 8 | |
| 9 | ## Description |
| 10 | The `hello-world:echo` command prints a greeting message to the console. By default, it prints "Hello world", but when provided with a name argument `hello-world:echo $1`, it prints "Hello ${1}". This command serves as a basic example of a Claude Code plugin implementation, demonstrating the minimal structure required for a functional plugin command. |
| 11 | |
| 12 | It provides a reference implementation for plugin developers. It demonstrates: |
| 13 | - Basic command structure |
| 14 | - Shell command execution within a plugin |
| 15 | - Handling arguments |
| 16 | - Minimal configuration requirements |
| 17 | |
| 18 | The spec sections is inspired by https://man7.org/linux/man-pages/man7/man-pages.7.html#top_of_page |
| 19 | |
| 20 | ## Implementation |
| 21 | - The command executes a simple bash `echo` statement |
| 22 | - Accepts an optional name argument (`$1`) |
| 23 | - If `$1` is provided, outputs "Hello $1" |
| 24 | - If no argument is provided, outputs "Hello world" |
| 25 | - Output is sent directly to standard output |
| 26 | - The command is stateless and has no side effects |
| 27 | |
| 28 | ## Examples |
| 29 | |
| 30 | 1. **Basic usage (no arguments)**: |
| 31 | ``` |
| 32 | /hello-world:echo |
| 33 | ``` |
| 34 | Output: |
| 35 | ``` |
| 36 | Hello world |
| 37 | ``` |
| 38 | |
| 39 | 2. **With a name argument**: |
| 40 | ``` |
| 41 | /hello-world:echo Alice |
| 42 | ``` |
| 43 | Output: |
| 44 | ``` |
| 45 | Hello Alice |
| 46 | ``` |
| 47 | |
| 48 | 3. **With multiple words as name**: |
| 49 | ``` |
| 50 | /hello-world:echo "John Doe" |
| 51 | ``` |
| 52 | Output: |
| 53 | ``` |
| 54 | Hello John Doe |
| 55 | ``` |