From 313e678fc1847ac28fc94c2a12d7f04f72ff1089 Mon Sep 17 00:00:00 2001 From: Tyler Erickson Date: Tue, 15 Oct 2024 14:25:16 -0600 Subject: [PATCH] ci: Trying a different method to reset permissions Signed-off-by: Tyler Erickson --- .github/workflows/meson.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/meson.yml b/.github/workflows/meson.yml index b04d807..7c00044 100644 --- a/.github/workflows/meson.yml +++ b/.github/workflows/meson.yml @@ -326,8 +326,9 @@ jobs: version=$(printf "%s-dev" $(date +'%y.%m.%d')) fi #Change ownership back before running deb/rpm creation - CURRENT_UID=$(id -u) - CURRENT_GID=$(id -g) + CURRENT_USER=$(whoami) + CURRENT_UID=$(getent passwd "$CURRENT_USER" | cut -d: -f3) + CURRENT_GID=$(getent passwd "$CURRENT_USER" | cut -d: -f4) sudo chown -R $CURRENT_UID:$CURRENT_GID build sed -i '/version:/ s/"[^"][^"]*"/"'"$version"'"/' ../../nfpm.yaml nfpm package -f ../../nfpm.yaml -p deb -t ..