We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 7e3ba69 + 68212f8 commit 66c0f6aCopy full SHA for 66c0f6a
lib/facter/mongodb_version.rb
@@ -2,7 +2,7 @@
2
setcode do
3
if Facter::Core::Execution.which('mongo')
4
mongodb_version = Facter::Core::Execution.execute('mongo --version 2>&1')
5
- %r{^MongoDB shell version:?\s+([\w\.]+)}.match(mongodb_version)[1]
+ %r{MongoDB shell version:?\s+v?([\w\.]+)}.match(mongodb_version)[1]
6
end
7
8
0 commit comments