From 3d0386f27ca66379acf50199e1d1298386eeeeb8 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 6 May 2024 02:55:53 +0200 Subject: Adding upstream version 3.2.1. Signed-off-by: Daniel Baumann --- scripts/embed-lua.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100755 scripts/embed-lua.sh (limited to 'scripts/embed-lua.sh') diff --git a/scripts/embed-lua.sh b/scripts/embed-lua.sh new file mode 100755 index 0000000..80f6cba --- /dev/null +++ b/scripts/embed-lua.sh @@ -0,0 +1,10 @@ +#!/bin/sh +set -e +# Clean unnecessary stuff from the lua file; note the significant tabulator. +alias strip="sed -e 's/^[ ]*//g; s/ */ /g; /^--/d; /^$/d'" +if command -v xxd > /dev/null 2>&1; then + strip < "$1" | xxd -i - +else + strip < "$1" | hexdump -v -e '/1 "0x%02X, " " "' +fi +exit $? -- cgit v1.2.3