From 2e9b775a2bb42a25517e51a1e6fdd431baf9fa21 Mon Sep 17 00:00:00 2001 From: Renata D'Avila Date: Mon, 24 Feb 2020 08:54:23 -0300 Subject: [PATCH] Add support for ARM architecture (#38) * Add support for ARM architecture * Test arm64 on travis * Check for arm64 Co-authored-by: Aldo D'Aquino --- .travis.yml | 17 +++++++++++------ certs.js | 5 ++++- 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/.travis.yml b/.travis.yml index 49367a2..dac7337 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,10 +1,15 @@ os: -- osx -- linux + - osx + - linux + +arch: + - amd64 + - arm64 language: node_js node_js: -- node -- 12 -- 10 -after_success: npm run coveralls + - node + - 12 + - 10 + +after_success: npm run coveralls \ No newline at end of file diff --git a/certs.js b/certs.js index 4c1a49e..f608f9b 100644 --- a/certs.js +++ b/certs.js @@ -43,7 +43,10 @@ function getExe() { case "darwin": return "mkcert-" + MKCERT_VERSION + "-darwin-amd64" case "linux": - return "mkcert-" + MKCERT_VERSION + "-linux-amd64" + if (process.arch === "arm" || process.arch === "arm64") + return "mkcert-" + MKCERT_VERSION + "-linux-arm" + else return "mkcert-" + MKCERT_VERSION + "-linux-amd64" + /* falls through */ case "win32": return "mkcert-" + MKCERT_VERSION + "-windows-amd64.exe" default: