allow comments in otherpkgs.pkglists with updatenode
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@5761 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
parent
0cb7925062
commit
20818652a1
@ -304,8 +304,7 @@ sub makescript {
|
||||
if (!$pkglist) { $pkglist=xCAT::SvrUtils->get_otherpkgs_pkglist_file_name("$::XCATROOT/share/xcat/$stat/$platform", $profile, $os, $arch); }
|
||||
}
|
||||
}
|
||||
print "pkglist=$pkglist\n";
|
||||
|
||||
# print "pkglist=$pkglist\n";
|
||||
if ($pkglist) {
|
||||
my @otherpkgs=();
|
||||
if (open(FILE1, "<$pkglist")) {
|
||||
@ -456,10 +455,13 @@ sub includefile
|
||||
return "#INCLUDEBAD:cannot open $file#";
|
||||
|
||||
while(<INCLUDE>) {
|
||||
chomp($_);
|
||||
s/\s+$//; #remove trailing spaces
|
||||
next if /^\s*$/; #-- skip empty lines
|
||||
push(@text, $_);
|
||||
chomp($_); #remove newline
|
||||
s/\s+$//; #remove trailing spaces
|
||||
next if /^\s*$/; #-- skip empty lines
|
||||
next if ( /^\s*#/ &&
|
||||
!/^\s*#INCLUDE:/ &&
|
||||
!/^\s*#NEW_INSTALL_LIST#/ ); #-- skip comments
|
||||
push(@text, $_);
|
||||
}
|
||||
|
||||
close(INCLUDE);
|
||||
|
Loading…
Reference in New Issue
Block a user