summaryrefslogtreecommitdiff
path: root/lib/oxidized/output
diff options
context:
space:
mode:
Diffstat (limited to 'lib/oxidized/output')
-rw-r--r--lib/oxidized/output/file.rb1
-rw-r--r--lib/oxidized/output/git.rb1
2 files changed, 2 insertions, 0 deletions
diff --git a/lib/oxidized/output/file.rb b/lib/oxidized/output/file.rb
index 03c878a..38c9917 100644
--- a/lib/oxidized/output/file.rb
+++ b/lib/oxidized/output/file.rb
@@ -33,6 +33,7 @@ class OxidizedFile < Output
IO.readlines File.join(cfg_dir, node)
else
path = Dir.glob File.join(cfg_dir, '**', node) # fetch node in all groups
+ return nil if path[0].nil?
open(path[0], 'r').readlines
end
end
diff --git a/lib/oxidized/output/git.rb b/lib/oxidized/output/git.rb
index d5eb8e7..e9256e8 100644
--- a/lib/oxidized/output/git.rb
+++ b/lib/oxidized/output/git.rb
@@ -99,6 +99,7 @@ class Git < Output
:parents => repo.empty? ? [] : [repo.head.target].compact,
:update_ref => 'HEAD',
)
+ index.write
end
end
end