]> git.proxmox.com Git - pve-client.git/commitdiff
register stanadard option 'pveclient-output-format'
authorDietmar Maurer <dietmar@proxmox.com>
Thu, 14 Jun 2018 07:36:54 +0000 (09:36 +0200)
committerDietmar Maurer <dietmar@proxmox.com>
Thu, 14 Jun 2018 07:36:54 +0000 (09:36 +0200)
PVE/APIClient/Commands/list.pm
PVE/APIClient/Config.pm

index db00da71256ffcdb78cd0bcea081f570db67c446..f12ef8718766820e137f007708a9a3e6640f5600 100644 (file)
@@ -20,13 +20,7 @@ __PACKAGE__->register_method ({
        additionalProperties => 0,
        properties => {
            remote => get_standard_option('pveclient-remote-name'),
        additionalProperties => 0,
        properties => {
            remote => get_standard_option('pveclient-remote-name'),
-           format => {
-               type => 'string',
-               description => 'Output format',
-               enum => [ 'table', 'json' ],
-               optional => 1,
-               default => 'table',
-           }
+           format => get_standard_option('pveclient-output-format'),
        },
     },
     returns => { type => 'null'},
        },
     },
     returns => { type => 'null'},
index 478e6589e2045e3a0647ad517bbf6007e491049e..ab84695d31875ad98a86c9a07a88d058dd579adb 100644 (file)
@@ -24,6 +24,14 @@ my $complete_remote_name = sub {
     return $list;
 };
 
     return $list;
 };
 
+PVE::APIClient::JSONSchema::register_standard_option('pveclient-output-format', {
+    type => 'string',
+    description => 'Output format.',
+    enum => [ 'table', 'json' ],
+    optional => 1,
+    default => 'table',
+});
+
 PVE::APIClient::JSONSchema::register_standard_option('pveclient-remote-name', {
     description => "The name of the remote.",
     type => 'string',
 PVE::APIClient::JSONSchema::register_standard_option('pveclient-remote-name', {
     description => "The name of the remote.",
     type => 'string',