rules: file encoding for PowerShell (Windows) and shell (Linux)
Add alwaysApply file-encoding rule, shell-spec, .editorconfig and .gitattributes templates so agents save .ps1 as UTF-8 BOM+CRLF and .sh as UTF-8+LF; document runtime JSON/spool without BOM. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
---
|
||||
description: Компактный shell/bash в выводе агента
|
||||
globs: **/*.{sh,bash}
|
||||
alwaysApply: false
|
||||
---
|
||||
|
||||
# Shell (Linux) — компактный вывод
|
||||
|
||||
- `set -euo pipefail` в bootstrap/install-скриптах, где уместно; не ломать интерактивные сценарии.
|
||||
- Кавычки вокруг переменных; `"$var"` вместо `$var`.
|
||||
- Без лишнего `echo` в библиотечных функциях — только UI/логи по делу.
|
||||
|
||||
## Кодировка и EOL
|
||||
|
||||
См. **`file-encoding.mdc`**: `.sh` — **UTF-8 без BOM**, **LF**. После правки на Windows — проверить отсутствие `\r`.
|
||||
Reference in New Issue
Block a user