Skip to content

Commit 6e25708

Browse files
authored
chore: update package versions to exact matches and add bunfig configuration (#44)
Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
1 parent 4e478e7 commit 6e25708

File tree

5 files changed

+36
-36
lines changed

5 files changed

+36
-36
lines changed

bun.lock

Lines changed: 11 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

bunfig.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[install]
2+
exact = true

package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -30,17 +30,17 @@
3030
"build:all": "bun ./script/build.ts"
3131
},
3232
"devDependencies": {
33-
"@straw-hat/prettier-config": "^3.1.5",
34-
"@types/bun": "latest",
35-
"@types/lodash.merge": "^4.6.9",
36-
"prettier": "^3.6.2"
33+
"@straw-hat/prettier-config": "3.1.5",
34+
"@types/bun": "1.2.2",
35+
"@types/lodash.merge": "4.6.9",
36+
"prettier": "3.6.2"
3737
},
3838
"peerDependencies": {
39-
"typescript": "^5"
39+
"typescript": "5.9.3"
4040
},
4141
"dependencies": {
42-
"lodash.merge": "^4.6.2",
43-
"yaml": "^2.8.1",
44-
"zod": "^4.1.12"
42+
"lodash.merge": "4.6.2",
43+
"yaml": "2.8.1",
44+
"zod": "4.1.12"
4545
}
4646
}

script/build.ts

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -38,19 +38,19 @@ for (const target of targets) {
3838

3939
const binary = target.os === 'windows' ? `${name}.exe` : name;
4040

41-
const result = await Bun.build({
42-
entrypoints: ['./src/cli.ts'],
43-
target: 'bun',
44-
compile: {
45-
target: target.bunTarget,
46-
outfile: `dist/${binary}`,
47-
},
48-
});
49-
50-
if (!result.success) {
41+
const result = await $`bun build --compile --target=${target.bunTarget} ./src/cli.ts --outfile dist/${binary}`
42+
.quiet()
43+
.nothrow();
44+
45+
if (result.exitCode !== 0) {
5146
console.error(`Failed to build ${target.os}-${target.arch}`);
52-
for (const log of result.logs) {
53-
console.error(log);
47+
const stdout = result.stdout.toString();
48+
const stderr = result.stderr.toString();
49+
if (stdout) {
50+
console.error(stdout);
51+
}
52+
if (stderr) {
53+
console.error(stderr);
5454
}
5555
process.exit(1);
5656
}

tsconfig.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@
2020
"noFallthroughCasesInSwitch": true,
2121
"noUncheckedIndexedAccess": true,
2222
"noImplicitOverride": true,
23-
"noImplicitReturns": true,
23+
24+
// Some stricter flags (disabled by default)
2425
"noUnusedLocals": true,
2526
"noUnusedParameters": true,
26-
"allowUnusedLabels": false,
27-
"allowUnreachableCode": false
27+
"noPropertyAccessFromIndexSignature": false
2828
}
2929
}

0 commit comments

Comments
 (0)