Gentoo Archives: gentoo-commits

From: Michael Palimaka <kensington@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/kde:master commit in: Documentation/maintainers/
Date: Fri, 26 Sep 2014 17:25:22
Message-Id: 1411752308.0007bb51630cb4b42a98edb19f174c2b81f70730.kensington@gentoo
1 commit: 0007bb51630cb4b42a98edb19f174c2b81f70730
2 Author: Michael Palimaka <kensington <AT> gentoo <DOT> org>
3 AuthorDate: Fri Sep 26 17:25:08 2014 +0000
4 Commit: Michael Palimaka <kensington <AT> gentoo <DOT> org>
5 CommitDate: Fri Sep 26 17:25:08 2014 +0000
6 URL: http://sources.gentoo.org/gitweb/?p=proj/kde.git;a=commit;h=0007bb51
7
8 [Documentation/maintainers] Add tool to quickly add new versioned sets.
9
10 ---
11 Documentation/maintainers/set-bump.sh | 49 +++++++++++++++++++++++++++++++++++
12 1 file changed, 49 insertions(+)
13
14 diff --git a/Documentation/maintainers/set-bump.sh b/Documentation/maintainers/set-bump.sh
15 new file mode 100755
16 index 0000000..d5a0fd7
17 --- /dev/null
18 +++ b/Documentation/maintainers/set-bump.sh
19 @@ -0,0 +1,49 @@
20 +#!/bin/sh
21 +
22 +# requires app-portage/portage-utils and app-portage/gentoolkit-dev
23 +
24 +: ${PORTDIR:="$(pwd)"}
25 +
26 +get_package_list_from_set() {
27 +
28 + local SET="${1}"
29 +
30 + for entry in $(grep -v ^[#@] "${PORTDIR}/sets/${SET}") ; do
31 + echo $(qatom ${entry} | cut -d " " -f 1-2 | tr " " "/")
32 + done
33 +
34 +}
35 +
36 +help() {
37 + echo Simple tool to bump a KDE set.
38 + echo
39 + echo Given a set name, copies the live set to the new set version
40 + echo and updates the package versions appropriately.
41 + echo
42 + echo Reads PORTDIR from your enviroment, defaulting to the current directory.
43 + echo
44 + echo Usage: set-bump.sh SETNAME DESTINATIONVERSION
45 + echo Example: set-bump.sh kde-plasma 5.1
46 + exit 0
47 +}
48 +
49 +
50 +SETNAME="$1"
51 +DESTINATIONVERSION="$2"
52 +
53 +if [[ $1 == "--help" ]] ; then
54 + help
55 +fi
56 +
57 +if [[ -z "${SETNAME}" || -z "${DESTINATIONVERSION}" ]] ; then
58 + echo ERROR: Not enough arguments
59 + echo
60 + help
61 +fi
62 +
63 +pushd "${PORTDIR}/sets" > /dev/null
64 +
65 +cp ${SETNAME}-live ${SETNAME}-${DESTINATIONVERSION}
66 +sed -e "s/~/</" -e "s/9999/${DESTINATIONVERSION}.50:5/" -i ${SETNAME}-${DESTINATIONVERSION}
67 +
68 +popd > /dev/null