aboutsummaryrefslogtreecommitdiffstats
path: root/package-list.bash
diff options
context:
space:
mode:
authorJohannes Löthberg <johannes@kyriasis.com>2014-09-17 22:00:06 +0100
committerJohannes Löthberg <johannes@kyriasis.com>2014-09-17 22:00:06 +0100
commit4fa7ba7dfaec774f246a1b4caedcd65fc4e3cd6f (patch)
tree23965a4e8d2b947f135503eea448b2850bd2b78e /package-list.bash
parenta6a584551a53928abfb1e9211df1563a89f6d5ce (diff)
downloadvcs-rebuild-4fa7ba7dfaec774f246a1b4caedcd65fc4e3cd6f.tar.xz
Refactor rebuild script
* Use one get_pkgver_sha() function for getting the commit SHA from the pkgver variable of a PKGBUILD * `makepkg --nobuild` updates the pkgver too, so store the old commit sha in an associative array using get_pkgver_sha before running `makepkg --nobuild`. * After updating the repos use get_pkgver_sha again to check whether the new pkgver is the same as the previous one using get_pkgver_sha() instead of the old monstreous get_new_commit() function. If it is do nothing, if not add the package to the list of packages to rebuild. * Use config.bash for configuration variables instead of keeping them inside the script. * Drop the packages associate array since makepkg is now used to refresh repositories and make it a normal array just containing the names of vcs packages instead. * Since makepkg takes care of refreshing repos we don't need to keep track of the branches ourself, so drop the branches associative array from the package list file.
Diffstat (limited to 'package-list.bash')
-rw-r--r--package-list.bash35
1 files changed, 16 insertions, 19 deletions
diff --git a/package-list.bash b/package-list.bash
index 590224b..9daf598 100644
--- a/package-list.bash
+++ b/package-list.bash
@@ -1,21 +1,18 @@
-declare -A packages=(
- [cower-git]="cower"
- [elementary-xfce-icons-git]="elementary-xfce"
- [goobook-git]="goobook"
- [gvim-hg]="vim"
- [i3pystatus-git]="i3pystatus"
- [isync-sasl-git]="isync"
- [j4-dmenu-desktop-git]="j4-dmenu-desktop"
- [kittypack-git]="kittypack"
- [mpv-git]="mpv"
- [mutt-kz-git]="mutt-kz"
- [termite-git]="termite"
- [termite-terminfo-git]="termite"
- [vte3-select-text-git]="vte"
- [weechat-git]="weechat"
+declare packages=(
+ "cower-git"
+ "elementary-xfce-icons-git"
+ "goobook-git"
+ "gvim-hg"
+ "i3pystatus-git"
+ "isync-sasl-git"
+ "j4-dmenu-desktop-git"
+ "kittypack-git"
+ "mpv-git"
+ "mutt-kz-git"
+ "termite-git"
+ "termite-terminfo-git"
+ "vte3-select-text-git"
+ "weechat-git"
)
-declare -A branches=(
- [vte3-select-text-git]="vte-0-36"
- [isync-sasl-git]="sasl"
-)
+declare -A old_version