diff options
| -rw-r--r-- | Swift/Packaging/Debian/update_debian_repo.sh | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/Swift/Packaging/Debian/update_debian_repo.sh b/Swift/Packaging/Debian/update_debian_repo.sh index d62a376..26c0d5b 100644 --- a/Swift/Packaging/Debian/update_debian_repo.sh +++ b/Swift/Packaging/Debian/update_debian_repo.sh | |||
| @@ -73,12 +73,23 @@ command -v reprepro >/dev/null 2>&1 || { echo >&2 "This script requires aptly bu | |||
| 73 | 73 | ||
| 74 | mkdir -p $APT_REPO_ROOT | 74 | mkdir -p $APT_REPO_ROOT |
| 75 | 75 | ||
| 76 | if [ -z ${SWIFT_PACKAGE_PLATFORMS+x} ]; then | ||
| 77 | platformsarray=( xenial yakkety jessie sid ) | ||
| 78 | else | ||
| 79 | platformsarray=( $SWIFT_PACKAGE_PLATFORMS ) | ||
| 80 | fi | ||
| 81 | |||
| 76 | # distros | 82 | # distros |
| 77 | for full_distribution_path in $INCOMING_FOLDER/{debian,ubuntu}/*; do | 83 | for full_distribution_path in $INCOMING_FOLDER/{debian,ubuntu}/*; do |
| 78 | distro_version=`basename $full_distribution_path` | 84 | distro_version=`basename $full_distribution_path` |
| 79 | distro_name=$(basename `dirname $full_distribution_path`) | 85 | distro_name=$(basename `dirname $full_distribution_path`) |
| 80 | distro_reprepro_root=${APT_REPO_ROOT}/${distro_name}/${distro_version} | 86 | distro_reprepro_root=${APT_REPO_ROOT}/${distro_name}/${distro_version} |
| 81 | 87 | ||
| 88 | if ! [[ $SWIFT_PACKAGE_PLATFORMS == *"$distro_name"* ]]; then | ||
| 89 | echo "$distro_name was not found in SWIFT_PACKAGE_PLATFORMS. Skipping..." | ||
| 90 | continue | ||
| 91 | fi | ||
| 92 | |||
| 82 | # ensure reprepro diretctory for this distribution version is present | 93 | # ensure reprepro diretctory for this distribution version is present |
| 83 | if [ ! -d "$distro_preprepro_root" ]; then | 94 | if [ ! -d "$distro_preprepro_root" ]; then |
| 84 | echo "Create distribution repository for $distro_name/$distro_version" | 95 | echo "Create distribution repository for $distro_name/$distro_version" |
| @@ -89,7 +100,7 @@ for full_distribution_path in $INCOMING_FOLDER/{debian,ubuntu}/*; do | |||
| 89 | write_reprepo_conf_incoming_to_file "${distro_reprepro_root}/conf/incoming" "$full_distribution_path" | 100 | write_reprepo_conf_incoming_to_file "${distro_reprepro_root}/conf/incoming" "$full_distribution_path" |
| 90 | fi | 101 | fi |
| 91 | 102 | ||
| 92 | # This is workaround for https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=808558 | 103 | # This is workaround for https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=808558 |
| 93 | # and https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=843402 | 104 | # and https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=843402 |
| 94 | if [ "$distro_name/$distro_version" = "debian/sid" ]; then | 105 | if [ "$distro_name/$distro_version" = "debian/sid" ]; then |
| 95 | sed -i '/dbgsym/ d' $full_distribution_path/*.changes | 106 | sed -i '/dbgsym/ d' $full_distribution_path/*.changes |
Swift