Skip to content
Back to skills

Path Portability

ASecurity

Use when code, installers, archives, configs, subprocesses, or scripts handle filesystem paths across machines.

  • 5 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 3, 2026
ai-agentsshellapi

Works with

  • api

Security analysis

A100/100

Scanned September 3, 2026

npx -y skills add ShugokiFable/Ultimate-AI-Starter-Bundle --skill path-portability --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Path Portability?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Path Portability
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/shugokifable-path-portability/badge)](https://www.skillsdirectory.com/skills/shugokifable-path-portability)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: path-portability
description: Use when code, installers, archives, configs, subprocesses, or scripts handle filesystem paths across machines.
---

# Path Portability

## Core rule
Paths must survive **spaces**, **Unicode**, alternate drives, different user homes, and invocation from a different working directory.

## Contract
- Resolve known roots at runtime; never embed another machine’s home or drive.
- Distinguish **absolute** paths from paths relative to the script/config that owns them.
- Quote only at the boundary that requires quoting; do not store shell-escaped strings as filesystem paths.
- Use path APIs rather than string concatenation.
- For subprocesses, pass argument arrays when the platform/API supports them.
- Test a path containing spaces, non-ASCII characters, and a different current directory.
- For archives, reject traversal (`..`), absolute members, and unsafe device names.

On Windows, verify PowerShell 5.1/cmd quoting separately from POSIX shells. A path that works at `C:\work` is not portability evidence.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…