From c07fecf8c214a2754033ca23e66afd4a38cacd27 Mon Sep 17 00:00:00 2001 From: Martin Perina Date: Mon, 9 May 2022 15:50:43 +0200 Subject: [PATCH] Fix marking repo dir for COPR as safe 2 Signed-off-by: Martin Perina --- .copr/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.copr/Makefile b/.copr/Makefile index 316b80998e6..1ad1e830d54 100644 --- a/.copr/Makefile +++ b/.copr/Makefile @@ -6,9 +6,10 @@ installdeps: srpm: installdeps # From git 2.35.2 we need to mark temporary directory, where the project is cloned to, as safe, otherwise # git commands won't work, and the remove afterwards to make git user config clean - $(eval REPO_DIR=$(shell sh -c pwd)) + $(eval REPO_DIR=$(shell pwd)) git config --global --add safe.directory ${REPO_DIR} $(eval SUFFIX=$(shell sh -c "echo '.git$$(git rev-parse --short HEAD)'")) + echo ${SUFFIX} git config --global --unset safe.directory ${REPO_DIR} # changing the spec file as passing -D won't preserve the suffix when rebuilding in mock sed "s:%{?release_suffix}:${SUFFIX}:" -i ovirt-engine.spec.in