mirror of
https://github.com/xcat2/xcat-core.git
synced 2025-05-31 01:56:39 +00:00
Merge pull request #3389 from immarvin/onrinstall
"rinstall xxx" command should be valid and perform provision by default
This commit is contained in:
commit
c1aa6dfcd5
@ -4,7 +4,6 @@
|
||||
package xCAT::Usage;
|
||||
use Getopt::Long;
|
||||
use xCAT::Utils;
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
=head1 xCAT::Usage
|
||||
@ -647,11 +646,11 @@ sub validateArgs {
|
||||
#filtered by GetOpt subroutine
|
||||
#fortunately the commands in this branch does not have such options
|
||||
foreach(@extrargs){
|
||||
if($_ !~ m/^-[-]?\S+/){
|
||||
if($_ and $_ !~ m/^-[-]?\S+/){
|
||||
$count+=1;
|
||||
}
|
||||
}
|
||||
if ($count!=1) {
|
||||
unless (($command =~ m/^(rinstall|winstall)$/ and $count==0) or $count==1) {
|
||||
return [1,"Invalid argument: '".join(" ",@extrargs)."'"];
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user