ilfenomeno-gif/powerofpolitcs.io/cross-platform-paths
Claude Code and agent skill by ilfenomeno-gif/powerofpolitcs.io
Trust tier 3
- community
Source check pending
Checking that the SKILL.md file is still in the repository.
Critical patterns for cross-platform path handling in this VS Code extension. Windows vs POSIX path bugs are the #1 source of issues. Use this skill when reviewing or writing path-related code.
Install
npx vskill@latest install ilfenomeno-gif/powerofpolitcs.io/cross-platform-pathsSKILL.md
The same SKILL.md was published earlier as nguyenhungtran18/skill-and-tool-tracker/cross-platform-paths.
Cross-Platform Path Handling
CRITICAL: This extension runs on Windows, macOS, and Linux. Path bugs are the #1 source of issues.
Core Rules
Rule 1: Never Concatenate Paths with /
Rule 2: Use path.resolve() for Comparisons, Not path.normalize()
Rule 3: Use Uri.file().fsPath for VS Code Paths
Platform-Specific Gotchas
Windows
| Issue | Details | |
|---|---|---|
| Drive letters | Paths start with C:\, D:\, etc. | |
| Backslashes | Separator is \, not / | |
| Case insensitivity | C:\Test equals c:\test | |
| Long paths | Paths >260 chars may fail | |
| Mapped drives | Z:\ may not be accessible | |
| pyenv-win | Uses pyenv.bat, not pyenv or pyenv.exe | |
| Poetry cache | %LOCALAPPDATA%\pypoetry\Cache\virtualenvs | |
| UNC paths | \\server\share\ format |
macOS
| Issue | Details | |
|---|---|---|
| Case sensitivity | Depends on filesystem (usually insensitive) | |
| Homebrew symlinks | Complex symlink chains in /opt/homebrew/ | |
| Poetry cache | ~/Library/Caches/pypoetry/virtualenvs | |
| XCode Python | Different from Command Line Tools Python |
Linux
| Issue | Details | |
|---|---|---|
| Case sensitivity | Paths ARE case-sensitive | |
| /bin symlinks | /bin may be symlink to /usr/bin | |
| XDG directories | ~/.local/share/virtualenvs for pipenv | |
| Poetry cache | ~/.cache/pypoetry/virtualenvs | |
| Hidden files | Dot-prefixed files are hidden |
Common Patterns
Getting Platform-Specific Paths
Environment-Specific Executable Names
Normalizing Paths for Comparison
Handling Uri | string Union Types
File Existence Checks
Shell Path Escaping
Testing Cross-Platform Code
When testing path-related code:
- Test on Windows (cmd, PowerShell, Git Bash)
- Test on macOS (zsh, bash)
- Test on Linux (bash, fish)
Pay special attention to:
- Paths with spaces:
C:\Program Files\Python - Paths with Unicode:
~/проекты/ - Very long paths (>260 chars on Windows)
- Paths with special characters:
$,&,(,)
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryChecking.antigravity/extensions/ms-python.vscode-python-envs-1.20.1-universal/.github/skills/cross-platform-paths/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/ilfenomeno-gif/powerofpolitcs.io/cross-platform-paths)