Fish script validation

VerifiedSafe

Validates fish scripts located in config/fish/ by performing syntax checks with fish --no-execute and formatting checks with fish_indent --check. This skill is automatically applied after editing any .fish file to ensure scripts are correct and properly formatted.

Sby Skills Guide Bot
DevelopmentIntermediate
706/2/2026
Claude CodeCursorWindsurf
#fish-shell#validation#linting#formatting#scripting

Recommended for

Our review

Validates Fish scripts after editing by performing syntax and formatting checks.

Strengths

  • Automates validation of .fish files to catch syntax errors early.
  • Uses fish_indent to enforce consistent formatting.
  • Integrates into the editing workflow for quick fixes.

Limitations

  • Only works with the Fish shell.
  • Does not validate plugin-managed files (e.g., _tide_).
  • Requires fish and fish_indent to be installed.
When to use it

Use this skill after every edit to a .fish file inside config/fish/.

When not to use it

Avoid using it for files from third-party plugins or non-Fish scripts.

Security analysis

Safe
Quality score85/100

The skill only runs fish syntax and formatting checks on designated .fish files, using safe commands (--no-execute and --check) and rewriting formatting. No destructive or exfiltrating actions.

No concerns found

Examples

Validate a fish function
Edit config/fish/functions/myfunc.fish to add a new function and then validate it.
Check formatting of all fish files
Run validation on all .fish files in config/fish/ and fix any formatting issues.
Fix syntax error in config.fish
I just modified config/fish/config.fish and it broke. Validate it and fix any errors.

name: fish-validate description: >- Validate fish scripts after editing. Apply when writing or modifying any .fish file in config/fish/. user-invocable: false allowed-tools: Bash, Read

After editing any .fish file in config/fish/, validate it:

1. Syntax check

fish --no-execute <file>

If syntax check fails, fix the issue before proceeding.

2. Format check

Run fish_indent to verify formatting:

fish_indent --check <file>

If formatting differs, apply it:

fish_indent -w <file>

Key files to never validate

  • Files inside config/fish/functions/ prefixed with _tide_ (managed by the tide prompt plugin)
Related skills