Skip to content

Commit

Permalink
feat: adds support for M1 macbooks to npm installer
Browse files Browse the repository at this point in the history
  • Loading branch information
EverlastingBugstopper committed Feb 22, 2021
1 parent ec435a5 commit 59dc414
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions installers/npm/binary.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,19 @@ const supportedPlatforms = [
RUST_TARGET: "x86_64-apple-darwin",
BINARY_NAME: name,
},
{
TYPE: "Darwin",
ARCHITECTURE: "arm64",
RUST_TARGET: "x86_64-apple-darwin",
BINARY_NAME: name,
},
];

const getPlatform = () => {
const type = os.type();
const architecture = os.arch();

for (let index in supportedPlatforms) {
let supportedPlatform = supportedPlatforms[index];
for (supportedPlatform of supportedPlatforms) {
if (
type === supportedPlatform.TYPE &&
architecture === supportedPlatform.ARCHITECTURE
Expand Down

0 comments on commit 59dc414

Please sign in to comment.