{"success":true,"name":"pin-text-encoding-and-line-endings-so-files-don-t-mutate-bet","description":"Files show garbled characters, phantom diffs, or scripts fail after changing machines","category":"ai-brimind","path":"ai-brimind/pin-text-encoding-and-line-endings-so-files-don-t-mutate-bet/SKILL.md","file":"SKILL.md","content":"---\nname: pin-text-encoding-and-line-endings-so-files-don-t-mutate-bet\ndescription: \"Files show garbled characters, phantom diffs, or scripts fail after changing machines\"\n---\n\n# Pin Text Encoding and Line Endings So Files Don't Mutate Between Machines\n\n## When to use\nAccented text displays wrong, every line of a file appears changed in version control, or a script breaks with an invisible character at the start or in line breaks.\n\n## Example request\né becomes Ã© after a save on another machine → two encodings interpreted one file; encoding mismatch. the diff shows all lines changed but text looks identical → line endings flipped between styles; CRLF/LF churn. a script fails on its very first line → an invisible byte-order mark sits before the text; hidden BOM. — each is bytes disagreeing under identical-looking text.\n\n## Instructions\nAct as a customs officer for text who knows that identical-looking documents can carry different bytes. Standardize the project once: text files are UTF-8 without a byte-order mark, and one line-ending style is chosen and enforced by the project's editor and version-control configuration files — committed to the repository so every machine and tool obeys automatically, instead of each editor imposing its habits. When symptoms appear, diagnose at the byte level: garbled accents mean a file written in one encoding was read as another — find which side is wrong and convert the file, never 'fix' the text by retyping it, which just hides the disease; whole-file diffs with no visible change mean line endings flipped — normalize them and check the enforcement config that should have prevented it; a failure at position zero or line one smells of an invisible leading mark — inspect the first bytes. Be strictest at borders: files received from users, exports for spreadsheet tools, and shell scripts (which some systems refuse with foreign line endings). Only proceed once the rules are enforced by committed configuration, not by team discipline.\n\n## Metadata\n- role: developer\n- level: tactical\n- places: vibeCoding\n- origin: ai.brimind.pro skill #750\n","linked_files":[],"origin":"ai.brimind.pro","owner_id":null,"source":"router"}