Skip to content

Commit

Permalink
@swc/cli: Switch to using @xhmikosr/bin-wrapper (#72)
Browse files Browse the repository at this point in the history
Fixes #54

This change switches out [the `@mole-inc/bin-wrapper`
package](https://github.com/mole-inc/bin-wrapper) for [the
`@xhmikosr/bin-wrapper`
package](https://github.com/XhmikosR/bin-wrapper). The former is
(seemingly) unmaintained now and has a vulnerability on the `execa`
version that is pulled in from `bin-check` v4. From what I can see, both
packages are forks of [the `bin-wrapper`
package](https://github.com/kevva/bin-wrapper), with each making some
slight tweaks and updates to dependencies. The only notable difference I
can see is that `@xhmikosr/bin-wrapper` has dropped support for Node <
18 while `@mole-inc/bin-wrapper` says that it supports Node 12 and up.
  • Loading branch information
strmer15 authored Nov 19, 2024
1 parent 184c46b commit aaec3de
Show file tree
Hide file tree
Showing 4 changed files with 462 additions and 622 deletions.
5 changes: 5 additions & 0 deletions .changeset/green-islands-camp.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@swc/cli": patch
---

@swc/cli: Switch to using @xhmikosr/bin-wrapper
2 changes: 1 addition & 1 deletion packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@
"spack": "./bin/spack.js"
},
"dependencies": {
"@mole-inc/bin-wrapper": "^8.0.1",
"@swc/counter": "workspace:^",
"@xhmikosr/bin-wrapper": "^13.0.5",
"commander": "^8.3.0",
"fast-glob": "^3.2.5",
"minimatch": "^9.0.3",
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/src/swcx/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import minVersion from "semver/ranges/min-version";
import { existsSync, readFileSync } from "fs";
import * as path from "path";
import { spawn, StdioOptions } from "child_process";
const { BinWrapper } = require("@mole-inc/bin-wrapper");
const { BinWrapper } = require("@xhmikosr/bin-wrapper");

const { platform, arch } = process;

Expand Down
Loading

0 comments on commit aaec3de

Please sign in to comment.