# Try Archify v3.3.2: review two immutable Git commits offline

26 November 2026 · Source-reviewed / not executed

## What you will learn

An agent review should cite the revision that was actually reviewed. Archify's local pinned review uses Git objects instead of a live PR or working tree. This exercise checks that a report identifies changed paths and source at two exact commits even when the working tree has moved. Static dependency analysis is not a substitute for executing tests.

## Prerequisites and cost

Git, Node.js 18+ (a supported LTS release recommended), shell, browser, disk space for the release source. The TypeScript parser is bundled in the tagged source according to the module README. No API key, model, paid service or remote PR is needed. Download the source before going offline; inspect third-party code before running it. Do not point this lab at a work repository or sensitive code. Budget 20–30 minutes after download.

## 1. Obtain the pinned tool

Download the v3.3.2 source archive from [the release](https://github.com/tt-a1i/archify/releases/tag/v3.3.2), extract to a disposable directory and set ARCHIFY to the absolute path of its inner archify package (the directory containing bin/archify.mjs). Alternatively use a local Git checkout of the tag on your own machine.

```sh
export ARCHIFY=/absolute/path/to/archify-3.3.2/archify
node --version
git --version
node "$ARCHIFY/bin/archify.mjs" code-analysis prepare --help
```

Expected: the tagged command supports --base and --head. If the bundled parser is missing, stop and check the tagged module README; do not silently switch to an unpinned version.

## 2. Make a controlled TypeScript fixture

```sh
LAB=$(mktemp -d)
mkdir "$LAB/repo"
cd "$LAB/repo"
git init
git config user.name "Local fixture"
git config user.email "fixture@example.invalid"
mkdir src
printf '{"compilerOptions":{"target":"ES2020","module":"commonjs"},"include":["src/**/*.ts"]}\n' > tsconfig.json
printf 'export const value = 1;\n' > src/main.ts
git add .
git commit -m baseline
BASE=$(git rev-parse HEAD)
printf 'export const offset = 2;\n' > src/offset.ts
printf 'import { offset } from "./offset";\nexport const value = 1 + offset;\n' > src/main.ts
git add .
git commit -m 'add local dependency'
HEAD_SHA=$(git rev-parse HEAD)
printf 'export const distractor = 999;\n' > src/main.ts
git status --porcelain > "$LAB/before.txt"
git diff --name-status "$BASE" "$HEAD_SHA"
git show "$HEAD_SHA:src/main.ts"
```

Expected ground truth: main.ts modified, offset.ts added, head has the import, dirty file has distractor instead. Record both full SHAs. Git commands operate only on the fixture.

## 3. Prepare the exact pair

```sh
GIT_ALLOW_PROTOCOL= GIT_NO_LAZY_FETCH=1 node "$ARCHIFY/bin/archify.mjs" code-analysis prepare "$LAB/repo" --base "$BASE" --head "$HEAD_SHA" --language ts --out "$LAB/review" > "$LAB/receipt.json"
git status --porcelain > "$LAB/after.txt"
diff -u "$LAB/before.txt" "$LAB/after.txt"
cat "$LAB/receipt.json"
```

The environment blocks Git transports and lazy fetching; it is not an OS-level network sandbox. For a stronger offline claim, disconnect networking after acquisition. Open the reported HTML path in a browser, typically review/analysis/repo.analysis.html. Inspect the changed-file list, base/head pins and captured source. Without a diagram, inspect file-level relations; do not assume a component-level diagram exists.

## 4. Negative control

Use a new output directory and a missing commit ID; this must not be reported as a successful analysis.

```sh
GIT_ALLOW_PROTOCOL= GIT_NO_LAZY_FETCH=1 node "$ARCHIFY/bin/archify.mjs" code-analysis prepare "$LAB/repo" --base 0000000000000000000000000000000000000001 --head "$HEAD_SHA" --language ts --out "$LAB/missing" > "$LAB/missing.json"
echo "Exit code: $?"
cat "$LAB/missing.json"
```

Expected: explicit missing-object error, not a valid review. Keep the successful output untouched. If output is empty, retain stderr and exit code; do not count an ambiguous crash as a pass.

## 5. Score the result

Award one point each: both exact SHAs visible; correct two changed paths; correct head import and base source; distractor excluded; working tree status unchanged; missing commit rejected explicitly. Record 0–6, actual CLI exit codes, receipt, screenshots and version. Expected target 6/6, not an observed result. If the report does not expose a criterion, mark it unverified rather than guessing. Repeat with a rename if useful, recording its separate result.

## Troubleshooting and limits

- Missing Git object: use a complete local fixture and exact 40-character SHAs, not a shallow/partial clone. Never enable lazy network fetch merely to pass the offline control.
- Unsupported Node or missing parser: inspect the tagged package and prerequisites; log setup failures separately.
- If dependency resolution is inconclusive, inspect coverage diagnostics and compare the exact import witness to git show. Do not infer runtime failure from a static edge.
- Do not upload the HTML: it can contain captured source. Clean up only the disposable directory when finished.
- The experiment establishes snapshot integrity for a tiny fixture, not general review accuracy, vulnerability detection or production performance.

## Sources

- [Release v3.3.2](https://github.com/tt-a1i/archify/releases/tag/v3.3.2)
- [Tagged usage reference](https://github.com/tt-a1i/archify/blob/v3.3.2/archify/modules/code-analysis/docs/USAGE.md)
- [Feature PR #1443](https://github.com/tt-a1i/archify/pull/1443)
- [Tagged package manifest](https://github.com/tt-a1i/archify/blob/v3.3.2/archify/package.json)

Validation: source-reviewed, not executed; all outputs above are expected or scoring criteria.
