This commit is contained in:
parent
a6466c5753
commit
3add02dfbd
1 changed files with 11 additions and 1 deletions
|
@ -48,6 +48,16 @@ jobs:
|
|||
- name: Deploy to repo
|
||||
run: |
|
||||
for apk in $FILELIST; do
|
||||
echo $APK
|
||||
branch=$(echo $apk | awk -F '/' '{print $2}')
|
||||
arch=$(echo $apk | awk -F '/' '{print $3}')
|
||||
name=$(echo $apk | awk -F '/' '{print $4}')
|
||||
|
||||
echo "Sending $name of arch $arch to $TARGET_REPO/$BASEBRANCH/$branch"
|
||||
return=$(curl -s --user $FORGE_REPO_USER\:$FORGE_REPO_TOKEN --upload-file $apk $TARGET_REPO/$BASEBRANCH/$branch 2>&1)
|
||||
if [ "$return" == "package file already exists" ]; then
|
||||
echo "Package already exists, refreshing..."
|
||||
curl -s --user $FORGE_REPO_USER\:$FORGE_REPO_TOKEN -X DELETE $TARGET_REPO/$BASEBRANCH/$branch/$arch/$name
|
||||
curl -s --user $FORGE_REPO_USER\:$FORGE_REPO_TOKEN --upload-file $apk $TARGET_REPO/$BASEBRANCH/$branch
|
||||
fi
|
||||
done
|
||||
|
||||
|
|
Loading…
Reference in a new issue