diff options
author | Jakub Jirutka <jakub@jirutka.cz> | 2016-09-23 01:25:44 +0200 |
---|---|---|
committer | Jakub Jirutka <jakub@jirutka.cz> | 2016-09-23 01:25:44 +0200 |
commit | 4e87fc7650c6918c586b2e15ba3e4ad8c65fc5c3 (patch) | |
tree | d60d683bb891a6c9307b5ed4d1648c79dbb77e0f /.travis/build-pkgs | |
parent | 5840a4815fb4e34c957a0edca4d0563f5b06d8ff (diff) | |
download | aports-4e87fc7650c6918c586b2e15ba3e4ad8c65fc5c3.tar.bz2 aports-4e87fc7650c6918c586b2e15ba3e4ad8c65fc5c3.tar.xz |
travis: fix set_repositories_for(), needs sudo
Diffstat (limited to '.travis/build-pkgs')
-rwxr-xr-x | .travis/build-pkgs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/.travis/build-pkgs b/.travis/build-pkgs index 57bbadd9f3..b6ab68a38e 100755 --- a/.travis/build-pkgs +++ b/.travis/build-pkgs @@ -38,15 +38,15 @@ changed_abuilds() { # $1: the target repository; main, community, or testing set_repositories_for() { local target_repo="$1" - local repos_file='/etc/apk/repositories' + local repos='' - printf '' > $repos_file local repo; for repo in main community testing; do - printf '%s\n' "$MIRROR_URI/$repo" >> $repos_file + repos="$repos $MIRROR_URI/$repo" [ "$repo" = "$target_repo" ] && break done - apk update + sudo printf '%s\n' $repos > /etc/apk/repositories + sudo apk update } |