From f614c8f0a0e24deae9fa61130f76057f6816bbba Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Tue, 6 Aug 2024 17:33:26 +0100 Subject: [PATCH] Fix permissions in release tarballs Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> --- scripts/package.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/package.sh b/scripts/package.sh index fb5aec9576..312ecfb42a 100755 --- a/scripts/package.sh +++ b/scripts/package.sh @@ -23,7 +23,9 @@ rm element-$version/config.json || true $(dirname $0)/normalize-version.sh ${version} > element-$version/version -tar chvzf dist/element-$version.tar.gz element-$version +# GNU/BSD compatibility workaround +tar_perms=(--owner=0 --group=0) && [ "$(uname)" == "Darwin" ] && sedi=(--uid=0 --gid=0) +gtar "${tar_perms[@]}" -chvzf dist/element-$version.tar.gz element-$version rm -r element-$version echo