From b189292ed6f2e0229919da280285ca3cf1bda0ae Mon Sep 17 00:00:00 2001 From: tomsmeding Date: Sun, 6 Feb 2022 13:16:16 +0100 Subject: Make install_prepare.sh more distro-independent --- install_prepare.sh | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/install_prepare.sh b/install_prepare.sh index ced8f40..d84b4d8 100755 --- a/install_prepare.sh +++ b/install_prepare.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env bash set -xeuo pipefail abbrgen_execname="modules/abbrgen/abbreviation_gen_`uname`" @@ -10,7 +10,8 @@ test -f modules/unicode/UnicodeData.txt || \ mkdir -p static/fonts test -f static/fonts/mononoki-Regular.woff || { - wget 'https://github.com/madmalik/mononoki/releases/download/1.2/mononoki.zip' -O /tmp/mononoki.zip - trap "rm /tmp/mononoki.zip" EXIT - unzip /tmp/mononoki.zip -d static/fonts/ + tmpdir=$(mktemp -d) + trap "rm -rf '$tmpdir'" EXIT + wget 'https://github.com/madmalik/mononoki/releases/download/1.2/mononoki.zip' -O "$tmpdir"/mononoki.zip + unzip "$tmpdir"/mononoki.zip -d static/fonts/ } -- cgit v1.2.3-70-g09d2