Skip to content

Commit 512899a

Browse files
committed
build: switch to git clone for src copy in tarball creation
Use git clone and clean to preserve repo state and ensure clean source tree. Signed-off-by: Kun Lai <laikun@linux.alibaba.com>
1 parent 0aabacc commit 512899a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Makefile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,9 @@ create-tarball:
4343
rm -fr /tmp/cryptpilot-tarball/cryptpilot-${VERSION}/vendor/winapi*/lib/*.lib
4444
rm -fr /tmp/cryptpilot-tarball/cryptpilot-${VERSION}/vendor/windows*/lib/*.lib
4545

46-
rsync -a --exclude target --exclude .git/modules/deps/cryptpilot-envoy ./ /tmp/cryptpilot-tarball/cryptpilot-${VERSION}/src
46+
# copy source code to src/
47+
git clone --no-hardlinks . /tmp/cryptpilot-tarball/cryptpilot-${VERSION}/src/
48+
cd /tmp/cryptpilot-tarball/cryptpilot-${VERSION}/src && git clean -xdf
4749

4850
tar -czf /tmp/cryptpilot-${VERSION}.tar.gz -C /tmp/cryptpilot-tarball/ cryptpilot-${VERSION}
4951

0 commit comments

Comments
 (0)