Skip to content

chore(ci): set up automated NPM publishing via workflow_dispatch - #4

Merged
B4nan merged 1 commit into
mainfrom
chore/setup-npm-publish-workflow
Apr 15, 2026
Merged

B4nan merged 1 commit into
mainfrom
chore/setup-npm-publish-workflow

Conversation

@B4nan

@B4nan B4nan commented Apr 14, 2026

Copy link
Copy Markdown
Member

Summary

Mirrors the publishing workflow from apify-eslint-config so this repo can be released the same way.

On manual `workflow_dispatch` (choose patch/minor/major or `none`):

  • bump `package.json` version
  • regenerate `CHANGELOG.md` from conventional commits with git-cliff
  • commit, tag, publish to NPM, push, and create a GitHub release

Also drops the old `publish.sh` script and the matching `prepublishOnly` guard — the workflow becomes the single source of truth.

Follow-up: once merged and a new version is released, apify/crawlee#3569 can drop its local yarn patch and just bump `@apify/tsconfig`.

Mirror the workflow from apify-eslint-config: on manual dispatch,
bump the version, regenerate CHANGELOG.md with git-cliff, publish
to NPM, tag the commit, and create a GitHub release.

Drop the ad-hoc publish.sh script and the prepublishOnly guard it
enforced — the workflow is now the single source of truth for
releases.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions github-actions Bot added this to the 138th sprint - Tooling team milestone Apr 14, 2026
@github-actions github-actions Bot added the t-tooling Issues with this label are in the ownership of the tooling team. label Apr 14, 2026
@B4nan
B4nan merged commit a5401ae into main Apr 15, 2026
1 check failed
@B4nan
B4nan deleted the chore/setup-npm-publish-workflow branch April 15, 2026 09:09
B4nan added a commit to apify/crawlee that referenced this pull request Apr 17, 2026
## Summary

Replaces ESLint + Biome with Oxlint + Oxfmt, modeled after [mikro-orm's
setup](https://github.com/mikro-orm/mikro-orm). Type-aware linting is
enabled via `oxlint-tsgolint` and the `--type-aware` flag. Lint + format
coverage spans `packages`, `test`, and `docs`.

## Notable config choices

- **`@apify/tsconfig` bumped to `^0.1.2`** — that release
(apify/apify-tsconfig#3, apify/apify-tsconfig#4) drops the deprecated
`importsNotUsedAsValues` option that `tsgolint` refuses to parse. No
local patch needed anymore.
- **Root tsconfigs drop `baseUrl`** — `tsgolint` removed support for it.
Non-relative imports under `test/*` and the one stray `packages/*`
import in `memory-storage` were converted to relative paths so the
mappings could be removed entirely.
- **Rules that were triggering across existing code** are fully enabled
as errors now. Violations fall into two buckets:
- Real issues fixed in-place (dead code after `throw`, `let`→`const`,
unnecessary template expressions, `.match` → `RegExp#exec`, `stream` →
`node:stream`, deprecated `z.ZodSchema` → `z.ZodType`).
- Patterns the rule flags pessimistically but that are correct
(`Promise.all(arr.map(fn))` where `fn` returns `Awaitable<void>`) —
fixed by marking the inner arrow `async`.
- **`typescript/no-deprecated` stays at `warn`** — we intentionally use
our own deprecated APIs in implementation code (`pseudoUrls`,
`experiments.requestLocking` opt-out, puppeteer page-level
cookies/postData/target). They're visible but don't block CI.
- **`no-misused-promises`** is configured with `{ checksVoidReturn: {
arguments: false } }`. Event-listener callbacks (`page.on(..., async)`)
and timer callbacks (`setInterval(async () => ...)`) are standard Node
patterns and the rule's default behavior is too strict.
- **`lint-staged`** runs `oxlint --fix` then `oxfmt --write`. A handful
of unsafe auto-fixes (`no-useless-default-assignment` strips
destructuring defaults, `return-await` removes `await` keywords,
`no-inferrable-types` occasionally strips default values) are turned off
so the fixer can run automatically without risk.

## Migration mechanics

- `eslint.config.mjs`, `biome.json`, and `tsconfig.eslint.json` are
removed. `.oxlintrc.json` + `.oxfmtrc.json` replace them.
- CI's lint job runs `yarn lint` + `yarn format:check`.
- `oxfmt` is set to 120 columns / 4-space / single quotes / `lf`,
matching the previous Biome setup. Markdown/MDX and release-managed
files (CHANGELOGs, package.json) are in its ignore list to avoid
cosmetic churn.

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
barjin pushed a commit to apify/crawlee that referenced this pull request Jul 20, 2026
Replaces ESLint + Biome with Oxlint + Oxfmt, modeled after [mikro-orm's
setup](https://github.com/mikro-orm/mikro-orm). Type-aware linting is
enabled via `oxlint-tsgolint` and the `--type-aware` flag. Lint + format
coverage spans `packages`, `test`, and `docs`.

- **`@apify/tsconfig` bumped to `^0.1.2`** — that release
(apify/apify-tsconfig#3, apify/apify-tsconfig#4) drops the deprecated
`importsNotUsedAsValues` option that `tsgolint` refuses to parse. No
local patch needed anymore.
- **Root tsconfigs drop `baseUrl`** — `tsgolint` removed support for it.
Non-relative imports under `test/*` and the one stray `packages/*`
import in `memory-storage` were converted to relative paths so the
mappings could be removed entirely.
- **Rules that were triggering across existing code** are fully enabled
as errors now. Violations fall into two buckets:
- Real issues fixed in-place (dead code after `throw`, `let`→`const`,
unnecessary template expressions, `.match` → `RegExp#exec`, `stream` →
`node:stream`, deprecated `z.ZodSchema` → `z.ZodType`).
- Patterns the rule flags pessimistically but that are correct
(`Promise.all(arr.map(fn))` where `fn` returns `Awaitable<void>`) —
fixed by marking the inner arrow `async`.
- **`typescript/no-deprecated` stays at `warn`** — we intentionally use
our own deprecated APIs in implementation code (`pseudoUrls`,
`experiments.requestLocking` opt-out, puppeteer page-level
cookies/postData/target). They're visible but don't block CI.
- **`no-misused-promises`** is configured with `{ checksVoidReturn: {
arguments: false } }`. Event-listener callbacks (`page.on(..., async)`)
and timer callbacks (`setInterval(async () => ...)`) are standard Node
patterns and the rule's default behavior is too strict.
- **`lint-staged`** runs `oxlint --fix` then `oxfmt --write`. A handful
of unsafe auto-fixes (`no-useless-default-assignment` strips
destructuring defaults, `return-await` removes `await` keywords,
`no-inferrable-types` occasionally strips default values) are turned off
so the fixer can run automatically without risk.

- `eslint.config.mjs`, `biome.json`, and `tsconfig.eslint.json` are
removed. `.oxlintrc.json` + `.oxfmtrc.json` replace them.
- CI's lint job runs `yarn lint` + `yarn format:check`.
- `oxfmt` is set to 120 columns / 4-space / single quotes / `lf`,
matching the previous Biome setup. Markdown/MDX and release-managed
files (CHANGELOGs, package.json) are in its ignore list to avoid
cosmetic churn.

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
B4nan added a commit to apify/crawlee that referenced this pull request Aug 12, 2026
Replaces ESLint + Biome with Oxlint + Oxfmt, modeled after [mikro-orm's
setup](https://github.com/mikro-orm/mikro-orm). Type-aware linting is
enabled via `oxlint-tsgolint` and the `--type-aware` flag. Lint + format
coverage spans `packages`, `test`, and `docs`.

- **`@apify/tsconfig` bumped to `^0.1.2`** — that release
(apify/apify-tsconfig#3, apify/apify-tsconfig#4) drops the deprecated
`importsNotUsedAsValues` option that `tsgolint` refuses to parse. No
local patch needed anymore.
- **Root tsconfigs drop `baseUrl`** — `tsgolint` removed support for it.
Non-relative imports under `test/*` and the one stray `packages/*`
import in `memory-storage` were converted to relative paths so the
mappings could be removed entirely.
- **Rules that were triggering across existing code** are fully enabled
as errors now. Violations fall into two buckets:
- Real issues fixed in-place (dead code after `throw`, `let`→`const`,
unnecessary template expressions, `.match` → `RegExp#exec`, `stream` →
`node:stream`, deprecated `z.ZodSchema` → `z.ZodType`).
- Patterns the rule flags pessimistically but that are correct
(`Promise.all(arr.map(fn))` where `fn` returns `Awaitable<void>`) —
fixed by marking the inner arrow `async`.
- **`typescript/no-deprecated` stays at `warn`** — we intentionally use
our own deprecated APIs in implementation code (`pseudoUrls`,
`experiments.requestLocking` opt-out, puppeteer page-level
cookies/postData/target). They're visible but don't block CI.
- **`no-misused-promises`** is configured with `{ checksVoidReturn: {
arguments: false } }`. Event-listener callbacks (`page.on(..., async)`)
and timer callbacks (`setInterval(async () => ...)`) are standard Node
patterns and the rule's default behavior is too strict.
- **`lint-staged`** runs `oxlint --fix` then `oxfmt --write`. A handful
of unsafe auto-fixes (`no-useless-default-assignment` strips
destructuring defaults, `return-await` removes `await` keywords,
`no-inferrable-types` occasionally strips default values) are turned off
so the fixer can run automatically without risk.

- `eslint.config.mjs`, `biome.json`, and `tsconfig.eslint.json` are
removed. `.oxlintrc.json` + `.oxfmtrc.json` replace them.
- CI's lint job runs `yarn lint` + `yarn format:check`.
- `oxfmt` is set to 120 columns / 4-space / single quotes / `lf`,
matching the previous Biome setup. Markdown/MDX and release-managed
files (CHANGELOGs, package.json) are in its ignore list to avoid
cosmetic churn.

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
B4nan added a commit to apify/crawlee that referenced this pull request Aug 18, 2026
Replaces ESLint + Biome with Oxlint + Oxfmt, modeled after [mikro-orm's
setup](https://github.com/mikro-orm/mikro-orm). Type-aware linting is
enabled via `oxlint-tsgolint` and the `--type-aware` flag. Lint + format
coverage spans `packages`, `test`, and `docs`.

- **`@apify/tsconfig` bumped to `^0.1.2`** — that release
(apify/apify-tsconfig#3, apify/apify-tsconfig#4) drops the deprecated
`importsNotUsedAsValues` option that `tsgolint` refuses to parse. No
local patch needed anymore.
- **Root tsconfigs drop `baseUrl`** — `tsgolint` removed support for it.
Non-relative imports under `test/*` and the one stray `packages/*`
import in `memory-storage` were converted to relative paths so the
mappings could be removed entirely.
- **Rules that were triggering across existing code** are fully enabled
as errors now. Violations fall into two buckets:
- Real issues fixed in-place (dead code after `throw`, `let`→`const`,
unnecessary template expressions, `.match` → `RegExp#exec`, `stream` →
`node:stream`, deprecated `z.ZodSchema` → `z.ZodType`).
- Patterns the rule flags pessimistically but that are correct
(`Promise.all(arr.map(fn))` where `fn` returns `Awaitable<void>`) —
fixed by marking the inner arrow `async`.
- **`typescript/no-deprecated` stays at `warn`** — we intentionally use
our own deprecated APIs in implementation code (`pseudoUrls`,
`experiments.requestLocking` opt-out, puppeteer page-level
cookies/postData/target). They're visible but don't block CI.
- **`no-misused-promises`** is configured with `{ checksVoidReturn: {
arguments: false } }`. Event-listener callbacks (`page.on(..., async)`)
and timer callbacks (`setInterval(async () => ...)`) are standard Node
patterns and the rule's default behavior is too strict.
- **`lint-staged`** runs `oxlint --fix` then `oxfmt --write`. A handful
of unsafe auto-fixes (`no-useless-default-assignment` strips
destructuring defaults, `return-await` removes `await` keywords,
`no-inferrable-types` occasionally strips default values) are turned off
so the fixer can run automatically without risk.

- `eslint.config.mjs`, `biome.json`, and `tsconfig.eslint.json` are
removed. `.oxlintrc.json` + `.oxfmtrc.json` replace them.
- CI's lint job runs `yarn lint` + `yarn format:check`.
- `oxfmt` is set to 120 columns / 4-space / single quotes / `lf`,
matching the previous Biome setup. Markdown/MDX and release-managed
files (CHANGELOGs, package.json) are in its ignore list to avoid
cosmetic churn.

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

t-tooling Issues with this label are in the ownership of the tooling team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants