From 3ad35ef0092775d2c301d4d201098ccdc341f5c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A1szl=C3=B3=20G=C3=96R=C3=96G?= Date: Mon, 7 Aug 2023 17:37:30 +0200 Subject: [PATCH] fix: use correct repository on arm64 ubuntu image --- Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Makefile b/Makefile index 863c1ba..51c3528 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,6 @@ HARDWARE = $(shell uname -m) SYSTEM_NAME = $(shell uname -s | tr '[:upper:]' '[:lower:]') +ARCH = $(shell dpkg --print-architecture) SHFMT_VERSION = 3.0.2 XUNIT_TO_GITHUB_VERSION = 0.3.0 XUNIT_READER_VERSION = 0.1.0 @@ -20,8 +21,12 @@ shellcheck: ifneq ($(shell shellcheck --version >/dev/null 2>&1 ; echo $$?),0) ifeq ($(SYSTEM_NAME),darwin) brew install shellcheck +else +ifeq ($(ARCH),arm64) + sudo add-apt-repository 'deb http://ports.ubuntu.com/ubuntu-ports focal-backports main restricted universe multiverse' else sudo add-apt-repository 'deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse' +endif sudo rm -rf /var/lib/apt/lists/* && sudo apt-get clean sudo apt-get update -qq && sudo apt-get install -qq -y shellcheck endif