v4-0002-ci-freebsd-repartition-script-didn-t-copy-.git-di.patch

text/plain

Filename: v4-0002-ci-freebsd-repartition-script-didn-t-copy-.git-di.patch
Type: text/plain
Part: 1
Message: Re: make dist using git archive

Patch

Format: format-patch
Series: patch v4-0002
Subject: ci: freebsd repartition script didn't copy .git directory
File+
src/tools/ci/gcp_freebsd_repartition.sh 1 1
From 2ba3315c75ff5f2a0123e6e0bc258e8bb4ae2f3a Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter@eisentraut.org>
Date: Thu, 21 Mar 2024 09:19:50 +0100
Subject: [PATCH v4 2/3] ci: freebsd repartition script didn't copy .git
 directory

We need a slightly different "cp" incantation to make sure top-level
"dot" files, such as ".git", are also copied.

This is relevant for example if a script wants to execute a git
command.  This currently does not happen, but it has come up while
testing other patches.

Discussion: https://www.postgresql.org/message-id/flat/40e80f77-a294-4f29-a16f-e21bc7bc75fc%40eisentraut.org
---
 src/tools/ci/gcp_freebsd_repartition.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/tools/ci/gcp_freebsd_repartition.sh b/src/tools/ci/gcp_freebsd_repartition.sh
index cc7f6bc35ef..3adb8fb88ec 100755
--- a/src/tools/ci/gcp_freebsd_repartition.sh
+++ b/src/tools/ci/gcp_freebsd_repartition.sh
@@ -23,4 +23,4 @@ du -hs $CIRRUS_WORKING_DIR
 mv $CIRRUS_WORKING_DIR $CIRRUS_WORKING_DIR.orig
 mkdir $CIRRUS_WORKING_DIR
 mount -o noatime /dev/md1 $CIRRUS_WORKING_DIR
-cp -r $CIRRUS_WORKING_DIR.orig/* $CIRRUS_WORKING_DIR/
+cp -a $CIRRUS_WORKING_DIR.orig/ $CIRRUS_WORKING_DIR/
-- 
2.44.0