Skip to content

Refactor removal policy and harden CI npm auth#21

Merged
Jercik merged 2 commits into
mainfrom
refactor-policy
May 1, 2026
Merged

Refactor removal policy and harden CI npm auth#21
Jercik merged 2 commits into
mainfrom
refactor-policy

Conversation

@Jercik
Copy link
Copy Markdown
Owner

@Jercik Jercik commented May 1, 2026

Summary

  • centralize runtime removal decisions in RemovalPolicy and thread policy through CLI orchestration/removal flow
  • remove duplicated flag checks by moving auto-confirm and dirty-warning decisions behind policy methods
  • harden workflows for private registry installs by configuring npm.j4k.dev auth in checks, release, and dedupe workflows while documenting fork PR secret constraints
  • pin package publishing to the public npm registry with publishConfig
  • align README Node.js requirement with package.json engines

Test plan

  • pnpm format:check
  • pnpm lint
  • pnpm typecheck
  • pnpm test
  • pnpm build
  • pnpm knip
  • pnpm fta

@cursor

This comment has been minimized.

github-actions[bot]

This comment was marked as resolved.

Jercik

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

@Jercik Jercik force-pushed the refactor-policy branch from 2127031 to a8d9fa6 Compare May 1, 2026 11:33
github-actions[bot]

This comment was marked as resolved.

@Jercik Jercik force-pushed the refactor-policy branch from a8d9fa6 to 84aa8cb Compare May 1, 2026 11:38
github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

@Jercik Jercik force-pushed the refactor-policy branch 2 times, most recently from 76dc1fd to eb9b3ae Compare May 1, 2026 11:52
@Jercik

This comment has been minimized.

github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

@Jercik Jercik force-pushed the refactor-policy branch from eb9b3ae to 9243f41 Compare May 1, 2026 11:57
@Jercik Jercik changed the title Refactor removal process to use a centralized RemovalPolicy interface… Refactor removal policy and harden CI npm auth May 1, 2026
github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

cursor[bot]

This comment was marked as resolved.

Consolidate runtime removal flags into a shared policy module to simplify
orchestration seams and improve maintainability.

Configure the quality-checks workflow to inject NPM_TOKEN for npm.j4k.dev,
then restore the managed oxlint-config-j4k setup used by this repository.

Made-with: Cursor
@Jercik Jercik force-pushed the refactor-policy branch from 9243f41 to f37bbad Compare May 1, 2026 12:07
@Jercik

This comment has been minimized.

github-actions[bot]

This comment was marked as resolved.

github-actions[bot]

This comment was marked as resolved.

Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Summary: No issues found.


Code review by Code Review 1 (gpt-5.5)

Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Summary: Found 1 info-level observation. Refactor preserves behavior; README and engines aligned correctly.


Code review by Code Review 2 (opus)

cache: "pnpm"

- name: Configure npm.j4k.dev auth
if: ${{ env.NPM_TOKEN != '' }}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ℹ️ Info: When NPM_TOKEN is missing/empty, this step silently skips and pnpm install --frozen-lockfile later fails with a cryptic registry auth error. The job-level if on line 13 already excludes fork PRs, so the only remaining case where NPM_TOKEN would be empty is a misconfigured repository secret — exactly when a fast, explicit failure helps the maintainer. release-npm.yml (lines 52–55) already does this with [ -z "${NPM_TOKEN}" ] && echo "NPM_TOKEN is required..." && exit 1. Consider matching that pattern here and in .github/workflows/dedupe-check.yml line 36 for consistency.

@Jercik Jercik merged commit 0e7f4ee into main May 1, 2026
6 checks passed
@Jercik Jercik deleted the refactor-policy branch May 1, 2026 12:27
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 1, 2026

🎉 This PR is included in version 1.4.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants