This repository has been archived by the owner on Jan 18, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 76
/
deploy-ppa.yml
43 lines (39 loc) · 1.78 KB
/
deploy-ppa.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
steps:
- task: DownloadBuildArtifacts@0
inputs:
artifactName: 'deb'
displayName: 'Download Debian artifacts'
- task: DownloadBuildArtifacts@0
inputs:
artifactName: 'imobiledevice-net'
displayName: 'Download imobiledevice-net artifacts'
- script: |
sudo apt-get update
sudo apt-get install -y libxml2-utils devscripts debhelper dh-autoreconf dput
displayName: 'Install dependencies'
- script: |
mkdir -p ~/.gnupg/
echo allow-loopback-pinentry > ~/.gnupg/gpg-agent.conf
gpg --allow-secret-key-import --import $BUILD_SOURCESDIRECTORY/ppa.asc
killall gpg-agent
echo "${GPG_PASSPHRASE}" >> /tmp/gpg_passphrase
displayName: 'Configure GPG'
- script: |
ls -l /tmp/gpg_passphrase
displayName: 'Determine passphrase'
- script: |
set -e
version_number=`xmllint --xpath 'Project/PropertyGroup/MobileDeviceDotNetNuGetVersion/text()' $SYSTEM_ARTIFACTSDIRECTORY/imobiledevice-net/Directory.Build.props`
cd $SYSTEM_ARTIFACTSDIRECTORY/deb/
declare -A package_versions
package_versions=( ["libplist"]="2.2.1" ["libusbmuxd"]="2.0.3" ["libimobiledevice"]="1.3.1" ["usbmuxd"]="1.1.2" ["libideviceactivation"]="1.1.2" ["ideviceinstaller"]="1.1.3" ["ios-webkit-debug-proxy"]="1.8.6")
for package in libplist libusbmuxd libimobiledevice usbmuxd libideviceactivation ideviceinstaller ios-webkit-debug-proxy
do
package_version=${package_versions[$package]}
debsign -S -k5314912C -p"$BUILD_SOURCESDIRECTORY/gpg-pass.sh /tmp/gpg_passphrase" ${package}_${package_version}-${version_number}-0${DIST}_source.changes
dput ppa:quamotion/ppa ${package}_${package_version}-${version_number}-0${DIST}_source.changes
done
displayName: Build Debian archives
- script: |
rm -rf /tmp/gpg_passphrase
displayName: 'Cleanup GPG key'