Browse Source

sde-update-package: remove extra location fields when setting a location, and remove trailing whitespacing

user/chris/test/early-mdev
Alejandro Mery 14 years ago
parent
commit
1dee73ef4a
1 changed files with 6 additions and 2 deletions
  1. +6
    -2
      lib/sde-package/package-update.awk

+ 6
- 2
lib/sde-package/package-update.awk

@ -2,7 +2,7 @@
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: lib/sde-package/package-update.awk
# Copyright (C) 2007 The OpenSDE Project
# Copyright (C) 2007 - 2011 The OpenSDE Project
#
# More information can be found in the files COPYING and README.
#
@ -31,8 +31,11 @@ else if ( $0 ~ /^\[D\]/ && $3 ~ ".*" oldver_pattern ".*" ) {
if ( filename != $3 ) {
$2 = 0;
$3 = filename;
if ( location > "" )
if ( location > "" ) {
$4 = location;
for (i=5;i<=NF;i++)
$i = "";
}
else if ( $4 ~ ".*/[0-9]+\\.[0-9]+/" ) {
ver = gensub( "([0-9]+\\.[0-9]+).*","\\1","", ver );
sub( "/[0-9]+\\.[0-9]+/", "/" ver "/", $4 );
@ -43,5 +46,6 @@ else if ( $0 ~ /^\[D\]/ && $3 ~ ".*" oldver_pattern ".*" ) {
}
}
sub(/[ \t]+$/, "")
print $0;
}

Loading…
Cancel
Save