Skip to content

armgit / rea

Public Imported from GitHub
0

Reverse engineer anything with agents, from app behavior down to native binaries.

Enforce local and CI quality gates

morluto8f035abb3a45
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 17b54b7f0..705faeb5a 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -53,7 +53,7 @@ jobs:
node-version: 22
cache: npm
- run: npm ci
- - run: npm run knip
+ - run: npm run lint:dead
duplicates:
name: Duplicate Code (jscpd)
@@ -89,7 +89,7 @@ jobs:
node-version: 22
cache: npm
- run: npm ci
- - run: npm test -- --reporter=verbose --reporter=junit --outputFile.junit=test-results.xml
+ - run: npm run test:coverage -- --reporter=verbose --reporter=junit --outputFile.junit=test-results.xml
- uses: actions/upload-artifact@v4
if: always()
with:
diff --git a/.husky/pre-commit b/.husky/pre-commit
index 4ae345c15..f3f510d27 100755
--- a/.husky/pre-commit
+++ b/.husky/pre-commit
@@ -1 +1,2 @@
-npx oxlint --fix
+npx lint-staged
+npm run typecheck
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 9f6821cbe..8b7fd4426 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -22,6 +22,18 @@ npm run verify:package
npm pack --dry-run
```
+`npm install` prepares the Husky pre-commit hook. Commits format and lint staged
+files with lint-staged, then typecheck the complete project. The normal test and
+CI coverage runs enforce the thresholds in `vitest.config.ts`; `npm run
+lint:dead` rejects unused files, exports, and dependencies.
+
+Set `REA_LOG_LEVEL` to `trace`, `debug`, `info`, `warn`, `error`, `fatal`, or
+`silent` to control structured JSON diagnostics. MCP mode defaults to `info` and
+always writes logs to stderr so the stdio protocol remains intact. One-shot CLI
+logging is opt-in and writes to stdout when a level is configured, preserving
+machine-readable command output by default. Request arguments, bridge
+authentication tokens, and environment data are redacted.
+
Changes that claim real Hopper behavior must also be tested against two distinct binaries:
```bash
diff --git a/knip.json b/knip.json
index 5fe7a94e2..bdff845d3 100644
--- a/knip.json
+++ b/knip.json
@@ -15,15 +15,15 @@
"ignore": ["dist/**", "docs/**", ".codex/**", ".devin/**"],
"ignoreDependencies": [],
"rules": {
- "files": "warn",
- "dependencies": "warn",
- "devDependencies": "warn",
+ "files": "error",
+ "dependencies": "error",
+ "devDependencies": "error",
"unlisted": "error",
- "exports": "warn",
- "nsExports": "warn",
- "types": "warn",
- "nsTypes": "warn",
- "enumMembers": "warn",
+ "exports": "error",
+ "nsExports": "error",
+ "types": "error",
+ "nsTypes": "error",
+ "enumMembers": "error",
"duplicates": "error"
}
}