summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith84@gmail.com>2019-12-20 16:34:35 -0800
committerTim Smith <tsmith84@gmail.com>2019-12-29 16:25:03 -0800
commit17088a9c92e3eeef3c60e53fbb33a29acfac25b8 (patch)
treee83fcb9a57421aa7c687eee09a85a865f871598a
parentb36a2da75e211422b87c1b35aa78980c4bb8055a (diff)
downloadwmi-lite-17088a9c92e3eeef3c60e53fbb33a29acfac25b8.tar.gz
Substitute require for require_relative
require_relative is significantly faster and should be used when available. Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r--lib/wmi-lite.rb4
-rw-r--r--lib/wmi-lite/wmi.rb8
-rw-r--r--lib/wmi-lite/wmi_exception.rb2
-rw-r--r--lib/wmi-lite/wmi_instance.rb2
4 files changed, 8 insertions, 8 deletions
diff --git a/lib/wmi-lite.rb b/lib/wmi-lite.rb
index 44375b3..2e89165 100644
--- a/lib/wmi-lite.rb
+++ b/lib/wmi-lite.rb
@@ -1,6 +1,6 @@
#
# Author:: Adam Edwards (<adamed@chef.io>)
-# Copyright:: Copyright 2014 Chef Software, Inc.
+# Copyright:: Copyright 2014-2019 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -16,4 +16,4 @@
# limitations under the License.
#
-require "wmi-lite/wmi"
+require_relative 'wmi-lite/wmi'
diff --git a/lib/wmi-lite/wmi.rb b/lib/wmi-lite/wmi.rb
index 2f54825..3d4331b 100644
--- a/lib/wmi-lite/wmi.rb
+++ b/lib/wmi-lite/wmi.rb
@@ -1,6 +1,6 @@
#
# Author:: Adam Edwards (<adamed@chef.io>)
-# Copyright:: Copyright 2014 Chef Software, Inc.
+# Copyright:: Copyright 2014-2019 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -16,9 +16,9 @@
# limitations under the License.
#
-require "win32ole" if RUBY_PLATFORM =~ /mswin|mingw32|windows/
-require "wmi-lite/wmi_instance"
-require "wmi-lite/wmi_exception"
+require 'win32ole' if RUBY_PLATFORM =~ /mswin|mingw32|windows/
+require_relative 'wmi_instance'
+require_relative 'wmi_exception'
module WmiLite
class Wmi
diff --git a/lib/wmi-lite/wmi_exception.rb b/lib/wmi-lite/wmi_exception.rb
index 7d97011..b950af3 100644
--- a/lib/wmi-lite/wmi_exception.rb
+++ b/lib/wmi-lite/wmi_exception.rb
@@ -1,6 +1,6 @@
#
# Author:: Adam Edwards (<adamed@chef.io>)
-# Copyright:: Copyright 2014 Chef Software, Inc.
+# Copyright:: Copyright 2014-2019 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/lib/wmi-lite/wmi_instance.rb b/lib/wmi-lite/wmi_instance.rb
index 947b3fa..752982f 100644
--- a/lib/wmi-lite/wmi_instance.rb
+++ b/lib/wmi-lite/wmi_instance.rb
@@ -1,6 +1,6 @@
#
# Author:: Adam Edwards (<adamed@chef.io>)
-# Copyright:: Copyright 2014 Chef Software, Inc.
+# Copyright:: Copyright 2014-2019 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");