fix: remove symlink reference, use CLAUDE_PLUGIN_ROOT paths directly
The symlink to ~/.local/bin is no longer needed since the command
can reference the script via ${CLAUDE_PLUGIN_ROOT}/scripts/.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
f963a8f388
commit
9a227204fd
@ -17,25 +17,23 @@ Use when the user asks to:
|
||||
|
||||
`${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py`
|
||||
|
||||
Also symlinked to `~/.local/bin/json-pretty` for PATH access.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
# From file
|
||||
json-pretty input.json
|
||||
python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py input.json
|
||||
|
||||
# From stdin/pipe
|
||||
cat data.json | json-pretty
|
||||
echo '{"foo":"bar"}' | json-pretty
|
||||
cat data.json | python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py
|
||||
echo '{"foo":"bar"}' | python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py
|
||||
|
||||
# Save to file
|
||||
json-pretty input.json -o output.json
|
||||
python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py input.json -o output.json
|
||||
|
||||
# Options
|
||||
json-pretty input.json --indent 4 # Custom indentation
|
||||
json-pretty input.json --sort-keys # Sort object keys
|
||||
json-pretty input.json --compact # Minify instead of prettify
|
||||
python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py input.json --indent 4 # Custom indentation
|
||||
python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py input.json --sort-keys # Sort object keys
|
||||
python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py input.json --compact # Minify instead of prettify
|
||||
```
|
||||
|
||||
## Options
|
||||
@ -49,17 +47,17 @@ json-pretty input.json --compact # Minify instead of prettify
|
||||
|
||||
**Prettify inline JSON:**
|
||||
```bash
|
||||
echo '{"name":"cal","items":[1,2,3]}' | json-pretty
|
||||
echo '{"name":"cal","items":[1,2,3]}' | python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py
|
||||
```
|
||||
|
||||
**Format a file:**
|
||||
```bash
|
||||
json-pretty messy.json -o clean.json
|
||||
python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py messy.json -o clean.json
|
||||
```
|
||||
|
||||
**Sort keys and use 4-space indent:**
|
||||
```bash
|
||||
json-pretty data.json --indent 4 --sort-keys
|
||||
python3 ${CLAUDE_PLUGIN_ROOT}/scripts/json-pretty.py data.json --indent 4 --sort-keys
|
||||
```
|
||||
|
||||
## Privacy Note
|
||||
|
||||
Loading…
Reference in New Issue
Block a user