linux_admin 0.20.0 → 0.20.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 45fe746b6f6401803b85ca5775c961a0fff87538
4
- data.tar.gz: 748af8054c1540f1337541dbf02f9626a9d91ed8
3
+ metadata.gz: 8fbe8f1b9631bcd133e5d04b63aaca507af5bdb0
4
+ data.tar.gz: 300558a8c030504cd37672da94040a579da3752c
5
5
  SHA512:
6
- metadata.gz: 8d31d976370bf3df926f66b0b075a2a3234b3f373faf4309eba1d1920163239e901297a9e846406e4c3e70429fcbb2c54feb01daef4cacc73e189468ad697ff0
7
- data.tar.gz: e49ec88d3c04c0e2d56a75ec02d9814b9866e1c3144941160c390cd55182548959e3aaa8306ffbd07a6f51d1ed76a00ec5228ecce0dd052d265775e2989f4aef
6
+ metadata.gz: 159f8ac175c2581203e01524eca99a4543be7bde8eb7f036e7a9189095ee960f5007ea3b8f3a207a0b4dfc2c2048332642193aec872623ffce96dd8aeba4eca7
7
+ data.tar.gz: bc77a27bc5abc9d3035de4b00df5da1677f0b7cdec58dcd9f339b3a113f88a295f464efbe93830297eea847481f676093163bedae572f47bb9007f097b652413
@@ -1,3 +1,3 @@
1
1
  module LinuxAdmin
2
- VERSION = "0.20.0".freeze
2
+ VERSION = "0.20.1".freeze
3
3
  end
data/lib/linux_admin.rb CHANGED
@@ -33,10 +33,18 @@ require 'linux_admin/ip_address'
33
33
  require 'linux_admin/dns'
34
34
  require 'linux_admin/network_interface'
35
35
  require 'linux_admin/chrony'
36
+ require 'forwardable'
36
37
 
37
38
  module LinuxAdmin
38
39
  class << self
40
+ extend Forwardable
41
+ extend Gem::Deprecate
39
42
  attr_writer :logger
43
+
44
+ def_delegators Common, :run
45
+ def_delegators Common, :run!
46
+ deprecate :run, "AwesomeSpawn.run", 2017, 6
47
+ deprecate :run!, "AwesomeSpawn.run!", 2017, 6
40
48
  end
41
49
 
42
50
  def self.logger
data/spec/common_spec.rb CHANGED
@@ -19,17 +19,19 @@ describe LinuxAdmin::Common do
19
19
  end
20
20
  end
21
21
 
22
- describe "#run" do
23
- it "runs a command with AwesomeSpawn.run" do
24
- expect(AwesomeSpawn).to receive(:run).with("echo", nil => "test")
25
- described_class.run("echo", nil => "test")
22
+ [described_class, LinuxAdmin].each do |klass|
23
+ describe "#{klass}.run" do
24
+ it "runs a command with AwesomeSpawn.run" do
25
+ expect(AwesomeSpawn).to receive(:run).with("echo", nil => "test")
26
+ klass.run("echo", nil => "test")
27
+ end
26
28
  end
27
- end
28
29
 
29
- describe "#run!" do
30
- it "runs a command with AwesomeSpawn.run!" do
31
- expect(AwesomeSpawn).to receive(:run!).with("echo", nil => "test")
32
- described_class.run!("echo", nil => "test")
30
+ describe "#{klass}.run!" do
31
+ it "runs a command with AwesomeSpawn.run!" do
32
+ expect(AwesomeSpawn).to receive(:run!).with("echo", nil => "test")
33
+ klass.run!("echo", nil => "test")
34
+ end
33
35
  end
34
36
  end
35
37
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: linux_admin
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.20.0
4
+ version: 0.20.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Dunne
@@ -20,7 +20,7 @@ authors:
20
20
  autorequire:
21
21
  bindir: bin
22
22
  cert_chain: []
23
- date: 2017-03-24 00:00:00.000000000 Z
23
+ date: 2017-04-21 00:00:00.000000000 Z
24
24
  dependencies:
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: bundler
@@ -311,7 +311,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
311
311
  version: '0'
312
312
  requirements: []
313
313
  rubyforge_project:
314
- rubygems_version: 2.5.1
314
+ rubygems_version: 2.5.2
315
315
  signing_key:
316
316
  specification_version: 4
317
317
  summary: LinuxAdmin is a module to simplify management of linux systems.