windows-compatibility

Normalizes Windows-safe paths, git commands, and ISO timestamps across platforms.

Updated Nov 27, 2024
One-click install
npx skills add https://github.com/Izak90/Izak90.github.io --skill windows-compatibility-izak90
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: windows-compatibility
Source: https://github.com/Izak90/Izak90.github.io/tree/main/isaac_treinos_ar_livre/.copilot/skills/windows-compatibility
Command: npx skills add https://github.com/Izak90/Izak90.github.io --skill windows-compatibility-izak90

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Squads face platform-specific assumptions across Windows/macOS/Linux. Issues include ISO timestamps with colons (illegal on Windows), git -C with Windows paths, and forward-slash paths in Node.js on Windows.

Core Features & Use Cases

  • Filenames & Timestamps: Never use colons in filenames; Use safeTimestamp() to replace colons with hyphens; Centralize formatting.
  • Git Commands: Never use git -C {path}; Always cd first; Check for changes with git diff --cached --quiet.
  • Commit Messages: Never embed newlines in -m; Use temp file and -F flag.
  • Paths: Never assume CWD is repo root; Use TEAM ROOT from spawn prompt or git rev-parse --show-toplevel; Use path.join() or path.resolve().

Quick Start

Adopt the Windows-friendly workflow: always cd into your repo before git commands and replace colon-containing timestamps with hyphens.

Frequently Asked Questions about windows-compatibility

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
Why do ISO timestamps cause errors on Windows during git workflows?

ISO timestamps cause errors on Windows because colons are illegal in filenames. You must sanitize timestamps using a safeTimestamp utility to replace colons with hyphens before using them in file path generation.

How do I handle git commands safely across Windows, macOS, and Linux?

To handle git commands safely across platforms, never use `git -C {path}` due to Windows path issues. Always cd into the repository directory first before executing git commands to ensure consistent behavior.

What is the best way to concatenate file paths in Node.js for cross-platform compatibility?

The best way to concatenate paths for cross-platform compatibility is using `path.join()` or `path.resolve()`. Never assume the current working directory is the repo root; instead, use `git rev-parse --show-toplevel` to find it.

How do I pass multi-line commit messages to git without breaking the workflow on Windows?

To pass multi-line commit messages safely on Windows, never embed newlines directly in the `-m` flag. Write your commit message to a temporary file and use the git `-F` flag to read from that file instead.

Does cross-platform path handling require checking the current working directory?

Yes, cross-platform path handling requires checking the current working directory because you should never assume CWD is the repo root. Extract the `TEAM ROOT` from the spawn prompt or run `git rev-parse --show-toplevel` to anchor paths correctly.