Skip to content

Commit 1587115

Browse files
committed
chore(release): prepare 0.12.0-beta.1
1 parent c1a3e9f commit 1587115

5 files changed

Lines changed: 23 additions & 8 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ All notable user-visible changes to Hunk are documented in this file.
1010

1111
### Fixed
1212

13-
## [0.12.0-beta.0] - 2026-05-10
13+
## [0.12.0-beta.1] - 2026-05-10
1414

1515
### Added
1616

@@ -22,6 +22,7 @@ All notable user-visible changes to Hunk are documented in this file.
2222

2323
### Fixed
2424

25+
- Fixed the prebuilt beta npm package so the `hunkdiff/opentui` export and bundled type declarations are included.
2526
- Made `hunk pager` emit static highlighted diff output for captured pager contexts like LazyGit, and pass diff input through unchanged when stdout is non-interactive.
2627
- Fixed Ctrl-Z job-control suspend support so Hunk can suspend and resume cleanly from a terminal.
2728
- Fixed Windows compatibility issues across paths, packaging, and tests.
@@ -303,8 +304,8 @@ All notable user-visible changes to Hunk are documented in this file.
303304

304305
- Stabilized diff repainting, active-hunk scrolling, syntax highlighting, pager stdin patch handling, and terminal cleanup on exit.
305306

306-
[Unreleased]: https://github.com/modem-dev/hunk/compare/v0.12.0-beta.0...HEAD
307-
[0.12.0-beta.0]: https://github.com/modem-dev/hunk/compare/v0.11.1...v0.12.0-beta.0
307+
[Unreleased]: https://github.com/modem-dev/hunk/compare/v0.12.0-beta.1...HEAD
308+
[0.12.0-beta.1]: https://github.com/modem-dev/hunk/compare/v0.11.1...v0.12.0-beta.1
308309
[0.11.1]: https://github.com/modem-dev/hunk/compare/v0.11.0...v0.11.1
309310
[0.11.0]: https://github.com/modem-dev/hunk/compare/v0.10.0...v0.11.0
310311
[0.10.0]: https://github.com/modem-dev/hunk/compare/v0.9.5...v0.10.0

docs/opentui-component.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Use `HunkDiffView` when you want a batteries-included single-file diff, or compo
77
## Install
88

99
```bash
10-
npm i hunkdiff @opentui/core @opentui/react react
10+
npm i hunkdiff @opentui/core@^0.1.88 @opentui/react@^0.1.88 react
1111
```
1212

1313
`hunkdiff` declares OpenTUI and React as peer dependencies, so install them in your app.

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "hunkdiff",
3-
"version": "0.12.0-beta.0",
3+
"version": "0.12.0-beta.1",
44
"description": "Desktop-inspired terminal diff viewer for understanding agent-authored changesets.",
55
"keywords": [
66
"ai",
@@ -48,9 +48,9 @@
4848
"dev": "bun --watch src/main.tsx",
4949
"build:npm": "bash ./scripts/build-npm.sh",
5050
"build:bin": "bash ./scripts/build-bin.sh",
51-
"build:prebuilt:npm": "bun run build:bin && bun run ./scripts/stage-prebuilt-npm.ts",
51+
"build:prebuilt:npm": "bun run build:npm && bun run build:bin && bun run ./scripts/stage-prebuilt-npm.ts",
5252
"build:prebuilt:artifact": "bun run build:bin && bun run ./scripts/build-prebuilt-artifact.ts",
53-
"stage:prebuilt:release": "bun run ./scripts/stage-prebuilt-npm.ts --artifact-root ./dist/release/artifacts",
53+
"stage:prebuilt:release": "bun run build:npm && bun run ./scripts/stage-prebuilt-npm.ts --artifact-root ./dist/release/artifacts",
5454
"install:bin": "bash ./scripts/install-bin.sh",
5555
"typecheck": "tsc --noEmit",
5656
"format": "oxfmt --write .",

scripts/check-prebuilt-pack.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,9 @@ if (!existsSync(metaDir)) {
6565
const metaPack = runPackDryRun(metaDir);
6666
assertPaths(metaPack, [
6767
"bin/hunk.cjs",
68+
"dist/npm/main.js",
69+
"dist/npm/opentui/index.d.ts",
70+
"dist/npm/opentui/index.js",
6871
"skills/hunk-review/SKILL.md",
6972
"README.md",
7073
"LICENSE",

scripts/stage-prebuilt-npm.ts

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ type RootPackageJson = {
3232
bugs?: unknown;
3333
license?: string;
3434
engines?: Record<string, string>;
35+
type?: string;
36+
exports?: unknown;
37+
dependencies?: Record<string, string>;
38+
peerDependencies?: Record<string, string>;
3539
};
3640

3741
interface BinaryArtifactMetadata {
@@ -78,6 +82,9 @@ function stageMetaPackage(
7882
const metaDir = path.join(releaseRoot, rootPackage.name);
7983
ensureDirectory(path.join(metaDir, "bin"));
8084
cpSync(path.join(repoRoot, "bin", "hunk.cjs"), path.join(metaDir, "bin", "hunk.cjs"));
85+
cpSync(path.join(repoRoot, "dist", "npm"), path.join(metaDir, "dist", "npm"), {
86+
recursive: true,
87+
});
8188
cpSync(path.join(repoRoot, "skills"), path.join(metaDir, "skills"), { recursive: true });
8289
cpSync(path.join(repoRoot, "README.md"), path.join(metaDir, "README.md"));
8390
cpSync(path.join(repoRoot, "LICENSE"), path.join(metaDir, "LICENSE"));
@@ -89,12 +96,16 @@ function stageMetaPackage(
8996
bin: {
9097
hunk: "./bin/hunk.cjs",
9198
},
92-
files: ["bin", "skills", "README.md", "LICENSE"],
99+
files: ["bin", "dist/npm", "skills", "README.md", "LICENSE"],
100+
type: rootPackage.type,
101+
exports: rootPackage.exports,
93102
keywords: rootPackage.keywords,
94103
repository: rootPackage.repository,
95104
homepage: rootPackage.homepage,
96105
bugs: rootPackage.bugs,
97106
engines: rootPackage.engines,
107+
dependencies: rootPackage.dependencies,
108+
peerDependencies: rootPackage.peerDependencies,
98109
optionalDependencies: buildOptionalDependencyMap(rootPackage.version, specs),
99110
license: rootPackage.license,
100111
publishConfig: {

0 commit comments

Comments
 (0)