From: Milton Miller Date: Thu, 22 Jul 2010 15:19:38 +0000 (-0500) Subject: setlocalversion: fix version for untaged nontip mercurial revs X-Git-Tag: MMI-PSA29.97-13-9~21410^2~22 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=55c640c3abff301eed5ee11c34a40bfe043c8c2d;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git setlocalversion: fix version for untaged nontip mercurial revs The manpage for cut says it will return all lines without the delimiter unless -s is specified. When I backed up my mecurial tree to generate modules, I found that the scm part of localversion was turning up blank. Signed-off-by: Milton Miller Cc: Michal Marek Cc: "Michał Górny" Signed-off-by: Michal Marek --- diff --git a/scripts/setlocalversion b/scripts/setlocalversion index 64a9cb5556cd..e90a91cc5185 100755 --- a/scripts/setlocalversion +++ b/scripts/setlocalversion @@ -86,7 +86,7 @@ scm_version() # Check for mercurial and a mercurial repo. if hgid=`hg id 2>/dev/null`; then - tag=`printf '%s' "$hgid" | cut -d' ' -f2` + tag=`printf '%s' "$hgid" | cut -s -d' ' -f2` # Do we have an untagged version? if [ -z "$tag" -o "$tag" = tip ]; then