gnu sed
This commit is contained in:
12
CLAUDE.md
12
CLAUDE.md
@@ -14,13 +14,13 @@ This repo uses Gitea (git.rev.iq) with the `tea` CLI for pull requests:
|
|||||||
- tea 0.10.1 is pinned in `nix/tea.nix` (0.11.x has TTY bugs)
|
- tea 0.10.1 is pinned in `nix/tea.nix` (0.11.x has TTY bugs)
|
||||||
- Always specify `-r igm/publisher-dashboard` flag (SSH remote auto-detection doesn't work)
|
- Always specify `-r igm/publisher-dashboard` flag (SSH remote auto-detection doesn't work)
|
||||||
|
|
||||||
## macOS sed Syntax
|
## sed Syntax (GNU coreutils)
|
||||||
|
|
||||||
macOS uses BSD sed which differs from GNU sed:
|
This project uses GNU coreutils via devenv, so use standard GNU sed syntax:
|
||||||
- In-place edit requires empty string for backup: `sed -i '' 's/old/new/g' file`
|
- In-place edit: `sed -i 's/old/new/g' file`
|
||||||
- GNU sed (Linux): `sed -i 's/old/new/g' file`
|
- Use `|` as delimiter when patterns contain `/`: `sed -i 's|old/path|new/path|g' file`
|
||||||
- Use `|` as delimiter when patterns contain `/`: `sed -i '' 's|old/path|new/path|g' file`
|
- For multiple files: `for f in *.txt; do sed -i 's/old/new/g' "$f"; done`
|
||||||
- For multiple files: `for f in *.txt; do sed -i '' 's/old/new/g' "$f"; done`
|
- Do NOT use BSD sed syntax (`sed -i ''`) - we have GNU sed available
|
||||||
|
|
||||||
## SvelteKit resolve() Usage
|
## SvelteKit resolve() Usage
|
||||||
|
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ in
|
|||||||
dbmate
|
dbmate
|
||||||
ast-grep
|
ast-grep
|
||||||
dbip-city-lite
|
dbip-city-lite
|
||||||
|
gnused # GNU sed for consistent cross-platform behavior
|
||||||
];
|
];
|
||||||
|
|
||||||
dotenv.enable = true;
|
dotenv.enable = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user