Repository navigation
v0.2.0
-
affected testsasks Vitest (3+) or Jest which test files and setup files it would run, and makes one entry per test file. Setup files are extra roots of each entry; runner configs are globals. -
A command after
--runs with the selection:{files}and{names}expand to it, an empty selection skips it, and a failed analysis runs it on everything. Strict selection is the default withtestsand with a command. -
--format paths|vitest|jest|playwrightprints the hit files, or runner arguments that run exactly them or nothing.--jsonand--namesremain as short forms. -
Glob entries:
-e 'src/**/*.test.ts'makes one entry per file git does not ignore; globs also expand inside-e name=….globEntries()andexpandGlobs()in the API. -
affected.config.{ts,mts,js,mjs,json}holds entries, globals, base, strict, types and test discovery;defineConfigkeeps entry names typed. Flags replace same-named entries and add to globals. -
GitHub Action
enekos/affected@v0: fetches the base and deepens shallow checkouts, runs a command on the selection, sets outputs and writes a job summary. Releases move thev0tag. -
--github-outputalso writesfiles,matrix,countandtotal;--github-summarywrites a Markdown table of hits and chains. -
--basedefaults toautowhen--changedis not given. -
Added per-entry uncertainty diagnostics, opt-in strict selection, traced dependency edges with a Node File Trace adapter, and shadow comparison against full Vitest or Jest JSON results.
-
npm v2/v3 lockfile changes select transitive consumers. Missing or unsupported lockfile information selects all entries.
-
pnpm v6/v9 and Yarn Berry lockfile changes select transitive consumers, following pnpm peer-suffixed snapshots and Yarn peer dependencies. Yarn classic and Bun lockfiles, unknown versions, and settings, override or patch changes still select all entries.
-
Fixed runtime and declaration export conditions, dynamic import comments, file-entry tsconfig inputs, config parent precedence, tracked symlinks, committed snapshots, module-relative CLI paths and Vite glob exclusions.
-
CLI option errors exit 2. CI examples propagate analysis errors.
-
Standalone
affectedbinary (Rust crateaffected-ts) for CI without Node: static Linux musl, macOS and Windows builds on each GitHub release with sha256 files,cargo binstallmetadata and a Homebrew formula template. Same flags and output as the Node CLI except shadow mode; readsaffected.config.jsonand adds--version.
npm: https://www.npmjs.com/package/@enekos/affected/v/0.2.0
Without Node: affected-<target>.tar.gz (.zip on Windows), each with a .sha256, or cargo binstall --git https://github.com/enekos/affected affected-ts.