Skip to content

Commit 298e25d

Browse files
committed
pushpkg: use -e and rsync only push directory
1 parent 1e9e13c commit 298e25d

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

pushpkg/pushpkg

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/bin/bash
1+
#!/bin/bash -e
22

33
ARGS_SSH=""
44
ARGS_RSYNC=""
@@ -72,9 +72,11 @@ if [ -z $COMPOMENT ]; then
7272
COMPOMENT="main"
7373
fi
7474

75-
sudo rm -fv debs/*
7675
ssh ${ARGS_SSH} ${USERNAME}@repo.aosc.io "mkdir -p /mirror/debs/pool/${BRANCH}/${COMPOMENT}"
77-
rsync ${ARGS_RSYNC} -rlOvhze ssh --progress debs/* ${USERNAME}@repo.aosc.io:/mirror/debs/pool/${BRANCH}/${COMPOMENT}
76+
77+
for i in debs/*/; do
78+
rsync ${ARGS_RSYNC} -rlOvhze ssh --progress $i ${USERNAME}@repo.aosc.io:/mirror/debs/pool/${BRANCH}/${COMPOMENT}
79+
done
7880

7981
if [ $AFTER_CLEAN_DIRECTORY = 1 ]; then
8082
rm -rfv ./*

0 commit comments

Comments
 (0)