mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-22 18:50:08 +03:00
F #4771: Allow onedb patch to accept arguments
This commit is contained in:
parent
32afd27e18
commit
8072555992
14
src/onedb/onedb
Executable file → Normal file
14
src/onedb/onedb
Executable file → Normal file
@ -207,6 +207,18 @@ SLAVE_BACKUP={
|
||||
:format => String
|
||||
}
|
||||
|
||||
###############################################################################
|
||||
# Extra options
|
||||
###############################################################################
|
||||
|
||||
EXTRA={
|
||||
:name => "extra",
|
||||
:large => "--extra arg",
|
||||
:description => "Extra args",
|
||||
:format => Array
|
||||
}
|
||||
|
||||
|
||||
cmd=CommandParser::CmdParser.new(ARGV) do
|
||||
description <<-EOT.unindent
|
||||
This command enables the user to manage the OpenNebula database. It
|
||||
@ -347,7 +359,7 @@ cmd=CommandParser::CmdParser.new(ARGV) do
|
||||
Applies a database patch file
|
||||
EOT
|
||||
|
||||
command :patch , patch_desc, :file, :options=>[BACKUP] do
|
||||
command :patch , patch_desc, :file, :options=>[BACKUP, EXTRA] do
|
||||
begin
|
||||
helper = OneDB.new(options)
|
||||
helper.patch(args[0], options)
|
||||
|
Loading…
x
Reference in New Issue
Block a user