Skip to content
Back to skills

Windows Path Formats

ASecurity

MSYS vs Windows paths for curl git Python and tools

  • 2 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added September 10, 2026
ai-agentspythonjavashellbashgit

Works with

  • cli

Security analysis

A100/100

Scanned September 10, 2026

npx -y skills add LoopyLuci/Skills --skill windows-path-formats --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Windows Path Formats?

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

Security grade badge for Windows Path Formats
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/loopyluci-windows-path-formats/badge)](https://www.skillsdirectory.com/skills/loopyluci-windows-path-formats)

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: windows-path-formats
description: "MSYS vs Windows paths for curl git Python and tools"
---

# Windows Path Formats (MSYS/git-bash)

When running in MSYS/git-bash on Windows, three path formats exist. Using the wrong one breaks tools.

## The Three Formats

| Format | Example | Works In |
|--------|---------|----------|
| MSYS/Unix | `/c/Users/Name/file.txt` | Bash, Python, git, ls, find |
| Windows | `C:\Users\Name\file.txt` | CMD, PowerShell, Windows apps |
| Windows quoted | `"C:\Users\Name\file.txt"` | curl -o, some CLI tools |

## Tool Compatibility

| Tool | Path Format to Use |
|------|-------------------|
| `ls`, `cd`, `cp`, `find` | MSYS: `/c/Users/...` |
| `python file.py` | MSYS: `/c/Users/...` |
| `curl -o` | Windows quoted: `"C:\Users\...\file.zip"` |
| `JAVA_HOME` | Windows double-backslash: `C:\\Users\\...` |
| `ANDROID_SDK_ROOT` | Windows double-backslash: `C:\\Users\\...` |
| `local.properties` | Forward slash: `C:/Users/...` |
| `MEDIA:` protocol | MSYS: `/c/Users/...` |
| Gradle/Java | Windows backslash: `C:\Users\...` |

## Quick Reference

```bash
# These work:
ls /c/Users/dubem/file.txt
cp /c/Users/dubem/file.txt /c/Projects/
python /c/Projects/app/main.py

# Use quoted Windows paths for curl:
curl -o "C:\Users\dubem\file.zip" https://example.com/file.zip

# Use Windows double-backslash for Java:
export JAVA_HOME="C:\\Users\\dubem\\jdk"
```

## Common Failures

| Command | Wrong | Right |
|---------|-------|-------|
| `curl -o /c/Users/x.zip URL` | ❌ Fails to write | ✅ `-o "C:\Users\x.zip"` |
| `export JAVA_HOME=/c/Users/jdk` | ❌ sdkmanager rejects | ✅ `C:\\Users\\jdk` |
| `unzip /c/Users/x.zip` | ✅ Works | Also works |
| `MEDIA:/c/Users/x.apk` | ✅ Works | Also `C:\Users\x.apk` |

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…