mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-22 18:50:08 +03:00
M #-: OneProvision array user inputs sep ; (#1119)
(cherry picked from commit 37bec51c56f596648e34ee2e755c477b346fce5c)
This commit is contained in:
parent
b7a2a5c16a
commit
cf6bacf67a
@ -529,7 +529,7 @@ module OneProvision
|
||||
when 'array'
|
||||
next unless input['default']
|
||||
|
||||
next if input['default'].match(/(\w+)(,\s*\w+)*/)
|
||||
next if input['default'].match(/(\w+)(;\s*\w+)*/)
|
||||
|
||||
return [false, "default #{input['default']} " \
|
||||
'invalid format']
|
||||
@ -675,7 +675,7 @@ module OneProvision
|
||||
case input['type']
|
||||
when 'array'
|
||||
value = []
|
||||
value << i_value.split(',')
|
||||
value << i_value.split(';')
|
||||
value.flatten!
|
||||
else
|
||||
value.gsub!("${#{match.join('.')}}", i_value.to_s)
|
||||
@ -808,7 +808,7 @@ module OneProvision
|
||||
when 'array'
|
||||
answer = ''
|
||||
|
||||
until answer.match(/(\w+)(,\s*\w+)*/)
|
||||
until answer.match(/(\w+)(;\s*\w+)*/)
|
||||
print "Array `#{input['name']}` " \
|
||||
"(default=#{input['default']}): "
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user