diff options
| author | Michael Palimaka <kensington@gentoo.org> | 2014-09-27 03:25:08 +1000 |
|---|---|---|
| committer | Michael Palimaka <kensington@gentoo.org> | 2014-09-27 03:25:08 +1000 |
| commit | 0007bb51630cb4b42a98edb19f174c2b81f70730 (patch) | |
| tree | f578f22854e6c08be56f2fa6d41c55b0a8978ed4 | |
| parent | cec2c69b2442cb4d3ad7c675d306de4b12651544 (diff) | |
| download | kde-0007bb51630cb4b42a98edb19f174c2b81f70730.tar.gz kde-0007bb51630cb4b42a98edb19f174c2b81f70730.tar.bz2 kde-0007bb51630cb4b42a98edb19f174c2b81f70730.zip | |
[Documentation/maintainers] Add tool to quickly add new versioned sets.
| -rwxr-xr-x | Documentation/maintainers/set-bump.sh | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/Documentation/maintainers/set-bump.sh b/Documentation/maintainers/set-bump.sh new file mode 100755 index 00000000000..d5a0fd7206c --- /dev/null +++ b/Documentation/maintainers/set-bump.sh @@ -0,0 +1,49 @@ +#!/bin/sh + +# requires app-portage/portage-utils and app-portage/gentoolkit-dev + +: ${PORTDIR:="$(pwd)"} + +get_package_list_from_set() { + + local SET="${1}" + + for entry in $(grep -v ^[#@] "${PORTDIR}/sets/${SET}") ; do + echo $(qatom ${entry} | cut -d " " -f 1-2 | tr " " "/") + done + +} + +help() { + echo Simple tool to bump a KDE set. + echo + echo Given a set name, copies the live set to the new set version + echo and updates the package versions appropriately. + echo + echo Reads PORTDIR from your enviroment, defaulting to the current directory. + echo + echo Usage: set-bump.sh SETNAME DESTINATIONVERSION + echo Example: set-bump.sh kde-plasma 5.1 + exit 0 +} + + +SETNAME="$1" +DESTINATIONVERSION="$2" + +if [[ $1 == "--help" ]] ; then + help +fi + +if [[ -z "${SETNAME}" || -z "${DESTINATIONVERSION}" ]] ; then + echo ERROR: Not enough arguments + echo + help +fi + +pushd "${PORTDIR}/sets" > /dev/null + +cp ${SETNAME}-live ${SETNAME}-${DESTINATIONVERSION} +sed -e "s/~/</" -e "s/9999/${DESTINATIONVERSION}.50:5/" -i ${SETNAME}-${DESTINATIONVERSION} + +popd > /dev/null |
