Windows-Safe Source Edits

    1

    Prevent and repair silent file corruption, encoding errors, and broken regex escapes in Windows dev environments.

    Free

    Security scanned

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+22 more

    Windows-Safe Source Edits

    Example session with this skill installed

    I need to update the regex in my python scripts across the project. I'm on Windows using PowerShell. Make sure the backslashes don't break.

    • Read your context and instructions
    • Compiled the windows-safe source edits

    I will update the regex patterns in your Python files. To prevent PowerShell from corrupting the backslashes or adding a UTF-8 BOM, I will use the internal editor tool for direct string replacement rather than a shell script. I will also run the byte-level validation script to confirm no control characters were introduced.

    File Integrity Audit

    FileStatusLine EndingsBOMIssues Found
    src/parser.pyVerifiedLFNoneNone
    src/utils/regex_helper.pyFixedLFNoneFound and removed 0x08 (Backspace)
    tests/test_parser.pyVerifiedLFNoneNone
    
    # Updated regex in src/parser.py
    # The replacement was performed using direct string injection to preserve backslashes.
    import re
    
    def parse_logs(line):
        # Safe edit: ensured \b remains two characters and not a backspace byte
        pattern = re.compile(r'\b(ERROR|WARN)\b')
        return pattern.findall(line)
    

    Next steps

    1. Run python scripts/check_text_files.py src/ to perform a final byte-level sweep.
    2. Execute one unit test that specifically exercises the \b boundary logic.
    3. If deploying to Linux, use scp to move the files instead of piping via ssh stdin.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    A regex that stops matching because \b became a backspace byte. Accents turned into é. A script that runs on the server but finds nothing because of an invisible BOM. These bugs compile, pass type-checks, and look fine on screen.

    This skill teaches your agent the five rules that prevent them on Windows (PowerShell, Git Bash, SSH to Linux).

    It also ships check_text_files.py, which detects control characters, BOMs, mixed line endings, mojibake and invalid UTF-8, and can repair mojibake after taking a backup.

    Includes an EXPERT.md reference (exact parameters, thresholds, failure diagnosis). Tested script: scripts/check_text_files.py.

    Note: the skill's own docs and its checker contain mojibake examples on purpose, so the checker flags them.

    How to use

    Skills on Agensi run inside your AI agent. Copy the prompt, paste it into your agent, and it connects to Agensi and installs this skill for you. If a payment is needed, your agent shows it to you first.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill passes our trust checks below.

    Security scanned

    Passed our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free forever

    No account required to browse

    Trust & safety

    Security scanned

    Verified clean today

    • Free to download with an account

    Requires

    Python 3 (standard library only — no third-party package)
    Git

    Listedtoday

    What's inside

    Frequently Asked Questions