From 6f864ab16d1fe95b5666523e47aa020e32b2c6d9 Mon Sep 17 00:00:00 2001 From: Faraz <83690012+t3dium@users.noreply.github.com> Date: Sun, 9 Jun 2024 22:12:20 +0000 Subject: [PATCH 1/3] fix install instructions to work with arm The install instructions currently assume the user is using x64, leading to it failing to fetch the correct binary on an arm device like rpi's. It'll now detect which arch is being used, and use the appropriate package. --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 4430cc0..ad15f7a 100644 --- a/README.md +++ b/README.md @@ -78,9 +78,9 @@ go build -ldflags "-X main.Version=$(git describe --tags)" or use [the pre-built binaries](https://github.com/FiloSottile/mkcert/releases). ``` -curl -JLO "https://dl.filippo.io/mkcert/latest?for=linux/amd64" -chmod +x mkcert-v*-linux-amd64 -sudo cp mkcert-v*-linux-amd64 /usr/local/bin/mkcert +arch=$(uname -m); if [ "$arch" = "x86_64" ]; then arch="amd64"; else arch="arm64"; fi && curl -JLO "https://dl.filippo.io/mkcert/latest?for=linux/$arch" +chmod +x mkcert-v*-linux-a*64 +sudo cp mkcert-v*-linux-a*64 /usr/local/bin/mkcert ``` For Arch Linux users, [`mkcert`](https://archlinux.org/packages/extra/x86_64/mkcert/) is available on the official Arch Linux repository. From 6bacea8834f46873211e9b3f63d0459f9a07ab3f Mon Sep 17 00:00:00 2001 From: Faraz <83690012+t3dium@users.noreply.github.com> Date: Sun, 9 Jun 2024 22:28:40 +0000 Subject: [PATCH 2/3] fix install instructions to work with arm64 and arm32 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ad15f7a..be77b58 100644 --- a/README.md +++ b/README.md @@ -78,7 +78,7 @@ go build -ldflags "-X main.Version=$(git describe --tags)" or use [the pre-built binaries](https://github.com/FiloSottile/mkcert/releases). ``` -arch=$(uname -m); if [ "$arch" = "x86_64" ]; then arch="amd64"; else arch="arm64"; fi && curl -JLO "https://dl.filippo.io/mkcert/latest?for=linux/$arch" +arch=$(uname -m); if [ "$arch" = "x86_64" ]; then arch="amd64"; elif [ "$arch" = "armv7l" ]; then arch="arm"; else arch="arm64"; fi && curl -JLO "https://dl.filippo.io/mkcert/latest?for=linux/$arch" chmod +x mkcert-v*-linux-a*64 sudo cp mkcert-v*-linux-a*64 /usr/local/bin/mkcert ``` From 22ab19da312fb11dd263d9e3efb4b0f9bf3a35a6 Mon Sep 17 00:00:00 2001 From: Faraz <83690012+t3dium@users.noreply.github.com> Date: Mon, 10 Jun 2024 12:25:31 +0000 Subject: [PATCH 3/3] fix install instructions to work with arm64 and arm32 Fixed an issue with the name of the package as the arm32 package won't have a "64" in the name. --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index be77b58..136b533 100644 --- a/README.md +++ b/README.md @@ -79,8 +79,8 @@ or use [the pre-built binaries](https://github.com/FiloSottile/mkcert/releases). ``` arch=$(uname -m); if [ "$arch" = "x86_64" ]; then arch="amd64"; elif [ "$arch" = "armv7l" ]; then arch="arm"; else arch="arm64"; fi && curl -JLO "https://dl.filippo.io/mkcert/latest?for=linux/$arch" -chmod +x mkcert-v*-linux-a*64 -sudo cp mkcert-v*-linux-a*64 /usr/local/bin/mkcert +chmod +x mkcert-v*-linux-a* +sudo cp mkcert-v*-linux-a* /usr/local/bin/mkcert ``` For Arch Linux users, [`mkcert`](https://archlinux.org/packages/extra/x86_64/mkcert/) is available on the official Arch Linux repository.