return $list;
};
-PVE::APIClient::JSONSchema::register_standard_option('pveclient-output-format', {
- type => 'string',
- description => 'Output format.',
- enum => [ 'text', 'json' ],
- optional => 1,
- default => 'text',
-});
-
PVE::APIClient::JSONSchema::register_standard_option('pveclient-remote-name', {
description => "The name of the remote.",
type => 'string',
return "$dir/config";
}
+sub lock_config {
+ my ($class, $timeout, $code, @param) = @_;
+
+ my $dir = PVE::APIClient::Helpers::configuration_directory();
+ make_path($dir);
+
+ my $filename = "$dir/.config.lck";
+
+ my $res = PVE::APIClient::Tools::lock_file($filename, $timeout, $code, @param);
+
+ die $@ if $@;
+
+ return $res;
+}
+
sub format_section_header {
my ($class, $type, $sectionId, $scfg, $done_hash) = @_;