From a429cda397d880d769b8c47ac8941465bf0f91a3 Mon Sep 17 00:00:00 2001 From: Tony Murray Date: Sat, 13 Feb 2016 13:09:57 -0600 Subject: Sort the config for AirOS Usually the config is sorted, but sometimes modifying the config moves things around. Using sort makes for nicer diffs. --- lib/oxidized/model/airos.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/oxidized/model') diff --git a/lib/oxidized/model/airos.rb b/lib/oxidized/model/airos.rb index 316c4f0..775005f 100644 --- a/lib/oxidized/model/airos.rb +++ b/lib/oxidized/model/airos.rb @@ -7,7 +7,7 @@ class Airos < Oxidized::Model cfg.split("\n").map { |line| "# #{line}" }.join("\n") + "\n" end - cmd 'cat /tmp/system.cfg' + cmd 'sort /tmp/system.cfg' cmd :secret do |cfg| cfg.gsub! /^(users\.\d+\.password|snmp\.community)=.+/, "# \\1=" -- cgit v1.2.1