Fix grep portability bug and document doc-drift script in CLAUDE.md
- Use grep -rE (ERE) instead of BRE \| alternation for BSD/macOS compat - Add doc-drift section to CLAUDE.md Testing section with usage and purpose Nightshift-Task: doc-drift Nightshift-Ref: https://github.com/marcus/nightshift
This commit is contained in:
@@ -79,7 +79,7 @@ function apiRouteExists(routePath) {
|
||||
const fragment = clean.replace(/^\/api/, '');
|
||||
try {
|
||||
const out = execSync(
|
||||
`grep -r --include="*.js" -l "${clean}\\|${fragment}" "${path.join(ROOT, 'server/src/routes')}"`,
|
||||
`grep -rE --include="*.js" -l "${clean}|${fragment}" "${path.join(ROOT, 'server/src/routes')}"`,
|
||||
{ stdio: ['pipe', 'pipe', 'pipe'] }
|
||||
).toString().trim();
|
||||
return out.length > 0;
|
||||
|
||||
Reference in New Issue
Block a user