This is an automated email from the git hooks/post-receive script. x2go pushed a change to branch master in repository buildscripts. from bdcaeb9 bin/build-rpm-package: fix --repo order in obs-build call. new 893c96a bin/build-rpm-package: add repeat_str() function to... repeat a string. new 3c9f2cb bin/build-rpm-package: add the easy part of create_mock_config(). new 78d822c bin/build-rpm-package: make repeat_str() function declaration consistent. The 3 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Summary of changes: bin/build-rpm-package | 53 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) -- Alioth's /srv/git/code.x2go.org/buildscripts.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/buildscripts.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository buildscripts. commit 893c96a40430d0eb7868019a4d55110f8bd5b1e1 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Apr 1 04:33:52 2015 +0200 bin/build-rpm-package: add repeat_str() function to... repeat a string. --- bin/build-rpm-package | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/bin/build-rpm-package b/bin/build-rpm-package index a598fc4..ca88489 100755 --- a/bin/build-rpm-package +++ b/bin/build-rpm-package @@ -168,6 +168,20 @@ check_mock_version_atleast () { fi } +# Repeats an input string. +# Returns the repeated input string. +repeat_str() { # INPUT COUNT + typeset INPUT="${1:?"Error: no input string passed to ${FUNCNAME}()."}" + typeset COUNT="${2:?"Error: no count passed to ${FUNCNAME}()."}" + + typeset ret="" + typeset -i i=0 + while [ "${i}" -lt "${COUNT}" ]; do + ret="${ret}$(printf "${INPUT}")" + done + printf "${ret}" +} + get_extra_repository () { typeset TYPE="${1:?"Error: no type passed to ${FUNCNAME}()."}" typeset DIST="${2:?"Error: no distribution passed to ${FUNCNAME}()."}" -- Alioth's /srv/git/code.x2go.org/buildscripts.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/buildscripts.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository buildscripts. commit 3c9f2cb4c63388d66903c448fd4b6769787918b4 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Apr 1 05:00:05 2015 +0200 bin/build-rpm-package: add the easy part of create_mock_config(). --- bin/build-rpm-package | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/bin/build-rpm-package b/bin/build-rpm-package index ca88489..5b60fa5 100755 --- a/bin/build-rpm-package +++ b/bin/build-rpm-package @@ -182,6 +182,45 @@ repeat_str() { # INPUT COUNT printf "${ret}" } +# Creates a custom mock config file given a base config (taken from +# /etc/mock/), a custom repository file (also taken from /etc/mock/), +# the build component and the target specification ("full" or "base"). +# Base refers to adding x2go-extras only, while full means also +# adding the full X2Go upstream repository with all published files. +# The created config file path is returned. +create_mock_config () { # MOCK_BASE CUSTOM_REPO COMPONENT TARGET + typeset MOCK_BASE="${1:?"Error: no mock base config passed to ${FUNCNAME}()."}" + typeset CUSTOM_REPO="${2:?"Error: no mock custom repository file passed to ${FUNCNAME}()."}" + typeset COMPONENT="${3:?"Error: no component (X2Go release group) passed to ${FUNCNAME}()."}" + typeset TARGET="${4:?"Error: no target (full or base) passed to ${FUNCNAME}()."}" + + typeset ret="" + + # Check argument sanity. + typeset i="" + for i in MOCK_BASE CUSTOM_REPO; do + # Must be plain file. + grep -q -s "/" <<< "${!i}" && { + echo "Error: ${i} parameter must not be a path but a simple file name." >&2 + exit -1 + } + + # Must exist. + if [ ! -f "/etc/mock/${!i}" ]; then + echo "Error: ${i} parameter must exist and be a regular file." >&2 + exit -1 + fi + done + + # Note: there is no way to check for the component's validity, + # as LTS releases have "random" names assigned to them. + + if [ "${TARGET}" != "base" ] && [ "${TARGET}" != "full" ]; then + echo "Error: TARGET parameter must be either full or base." >&2 + exit -1 + fi +} + get_extra_repository () { typeset TYPE="${1:?"Error: no type passed to ${FUNCNAME}()."}" typeset DIST="${2:?"Error: no distribution passed to ${FUNCNAME}()."}" -- Alioth's /srv/git/code.x2go.org/buildscripts.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/buildscripts.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository buildscripts. commit 78d822ccd277fc37dae9faea5a7d3f0058c64482 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Apr 1 05:01:00 2015 +0200 bin/build-rpm-package: make repeat_str() function declaration consistent. --- bin/build-rpm-package | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/build-rpm-package b/bin/build-rpm-package index 5b60fa5..db99a0d 100755 --- a/bin/build-rpm-package +++ b/bin/build-rpm-package @@ -170,7 +170,7 @@ check_mock_version_atleast () { # Repeats an input string. # Returns the repeated input string. -repeat_str() { # INPUT COUNT +repeat_str () { # INPUT COUNT typeset INPUT="${1:?"Error: no input string passed to ${FUNCNAME}()."}" typeset COUNT="${2:?"Error: no count passed to ${FUNCNAME}()."}" -- Alioth's /srv/git/code.x2go.org/buildscripts.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/buildscripts.git