diff options
author | John Southworth <john.southworth@vyatta.com> | 2011-07-14 18:03:43 -0500 |
---|---|---|
committer | John Southworth <john.southworth@vyatta.com> | 2011-07-14 18:03:43 -0500 |
commit | 5aeb46dbdb903a1921bd38e5bfc1acd53cd08c6a (patch) | |
tree | 73194d3987ca390b4b42a5637689016b67f2d8a9 /scripts | |
parent | 3348752ce3da1573eab09c0f61fa641e881ec796 (diff) | |
download | vyatta-cfg-5aeb46dbdb903a1921bd38e5bfc1acd53cd08c6a.tar.gz vyatta-cfg-5aeb46dbdb903a1921bd38e5bfc1acd53cd08c6a.zip |
Bugfix 7331: Napa timeframe fix for config migration commment bug. Will investigate if this is a viable long term fix or if we want to find another way to ignore migrated comments for oxnard
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/vyatta-save-config.pl | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/scripts/vyatta-save-config.pl b/scripts/vyatta-save-config.pl index 178eff7..51417b6 100755 --- a/scripts/vyatta-save-config.pl +++ b/scripts/vyatta-save-config.pl @@ -103,12 +103,13 @@ if ($mode eq 'local') { } select $save; -my @show_cmd = ('cli-shell-api', 'showConfig', '--show-active-only', - '--show-ignore-edit'); +my $show_cmd = 'cli-shell-api showConfig --show-active-only --show-ignore-edit'; if ($show_default) { - push @show_cmd, '--show-show-defaults'; + $show_cmd .= ' --show-show-defaults'; } -open(my $show_fd, '-|', @show_cmd) or die 'Cannot execute config output'; +$show_cmd .= "| sed -e \'/--- CONFIGURATION COMMENTED OUT DURING MIGRATION BELOW ---/"; +$show_cmd .= ",/--- CONFIGURATION COMMENTED OUT DURING MIGRATION ABOVE ---/d\'"; +open(my $show_fd, '-|', $show_cmd) or die 'Cannot execute config output'; while (<$show_fd>) { print; } |