scone 0.1.8 → 0.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1d64f4f9ea56d29a7332f66027872d77346bbfdde74b2ee53127b202b7e76205
4
- data.tar.gz: e2c4039fc5dc29bf34d6f54941a01d563e1e8a5b79a1bd5e5b74d005fe6d1682
3
+ metadata.gz: 5ea0f30952780b892268b6c4dfa5a064a8a8b601786fe45014ec03692d9ea8d4
4
+ data.tar.gz: bb63bb0b4700f68560e60d4d9dea2e2775e96738a547a583245feb4876b8f5f3
5
5
  SHA512:
6
- metadata.gz: 96e3d1888d6f9c20aa5d1ab5d06736d6e9c113d20d45d0d36a24ef4c549a1a4705d0dddbb29b5b0101350bbcbc43dd3329a86c1f62e8f4a428ed844d4ed83496
7
- data.tar.gz: 5d379fd75ce99aa29027b17137bda3df98ec3020c350d14e1f59ced7e5b88cce78a36ed8bc1bd73789b3c7c58dd279115a53c37ccdd80e1427bfdd6565973295
6
+ metadata.gz: a9def8d44c1f915edebac6b5e86e6a7bc490e347a01415853249a37a54ceeb68b009062c8230c3334f1378be9ce0205f4473a1a168602fb3890b9c793eff724a
7
+ data.tar.gz: c2d1ec351c47df702f62a617deb13ae94bd171edc12339e000dc37a79189b03c4979902d0243373041915ad2a126e1168d933fd6df6402e2de7c20c52f2ecfd9
data/.rubocop.yml CHANGED
@@ -1,5 +1,9 @@
1
1
  inherit_gem:
2
2
  rubocop-shopify: rubocop.yml
3
3
 
4
+ AllCops:
5
+ NewCops: enable
6
+ TargetRubyVersion: 2.6
7
+
4
8
  Style/SymbolProc:
5
9
  Enabled: false
data/Gemfile.lock CHANGED
@@ -1,12 +1,14 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- scone (0.1.8)
4
+ scone (0.1.9)
5
+ awesome_spawn (~> 1.5)
5
6
 
6
7
  GEM
7
8
  remote: https://rubygems.org/
8
9
  specs:
9
10
  ast (2.4.2)
11
+ awesome_spawn (1.5.0)
10
12
  diff-lcs (1.4.4)
11
13
  parallel (1.21.0)
12
14
  parser (3.0.2.0)
data/cache/.gitignore CHANGED
@@ -1,3 +1,4 @@
1
1
  *
2
2
  !proc.stat.txt
3
+ !ifconfig.txt
3
4
  !.gitignore
@@ -0,0 +1,18 @@
1
+ eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
2
+ inet 104.248.58.9 netmask 255.255.240.0 broadcast 104.248.63.255
3
+ inet6 2604:a880:400:d0::1986:5001 prefixlen 64 scopeid 0x0<global>
4
+ inet6 fe80::5074:3eff:fe15:d08b prefixlen 64 scopeid 0x20<link>
5
+ ether 52:74:3e:15:d0:8b txqueuelen 1000 (Ethernet)
6
+ RX packets 663200 bytes 90827363 (90.8 MB)
7
+ RX errors 0 dropped 0 overruns 0 frame 0
8
+ TX packets 652332 bytes 479484344 (479.4 MB)
9
+ TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
10
+
11
+ lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
12
+ inet 127.0.0.1 netmask 255.0.0.0
13
+ inet6 ::1 prefixlen 128 scopeid 0x10<host>
14
+ loop txqueuelen 1000 (Local Loopback)
15
+ RX packets 0 bytes 0 (0.0 B)
16
+ RX errors 0 dropped 0 overruns 0 frame 0
17
+ TX packets 0 bytes 0 (0.0 B)
18
+ TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
@@ -0,0 +1,43 @@
1
+ # frozen_string_literal: true
2
+
3
+ #
4
+ # Scone - A Unified SDK for Linux OS Distributions in Ruby
5
+ #
6
+ # Licensed under the Apache License, Version 2.0 (the "License");
7
+ # you may not use this file except in compliance with the License.
8
+ # You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing, software
13
+ # distributed under the License is distributed on an "AS IS" BASIS,
14
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ # See the License for the specific language governing permissions and
16
+ # limitations under the License.
17
+ #
18
+
19
+ require "awesome_spawn"
20
+
21
+ # Scone Module
22
+ module Scone
23
+ # Command Class
24
+ class Command
25
+ def initialize(command)
26
+ @command = command
27
+ end
28
+
29
+ def run
30
+ result = AwesomeSpawn.run(@command)
31
+ @exit_status = result.exit_status
32
+ @command_line = result.command_line
33
+ @output = result.output
34
+ @error = result.error
35
+ @exit_status
36
+ end
37
+
38
+ attr_reader :exit_status
39
+ attr_reader :command_line
40
+ attr_reader :output
41
+ attr_reader :error
42
+ end
43
+ end
@@ -0,0 +1,27 @@
1
+ # frozen_string_literal: true
2
+
3
+ #
4
+ # Scone - A Unified SDK for Linux OS Distributions in Ruby
5
+ #
6
+ # Licensed under the Apache License, Version 2.0 (the "License");
7
+ # you may not use this file except in compliance with the License.
8
+ # You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing, software
13
+ # distributed under the License is distributed on an "AS IS" BASIS,
14
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ # See the License for the specific language governing permissions and
16
+ # limitations under the License.
17
+ #
18
+
19
+ # Scone Module
20
+ module Scone
21
+ # Ubuntu Module
22
+ module Ubuntu
23
+ # IP Address Class
24
+ class IPAddr
25
+ end
26
+ end
27
+ end
data/lib/scone/version.rb CHANGED
@@ -18,5 +18,5 @@
18
18
 
19
19
  # Scone Module
20
20
  module Scone
21
- VERSION = "0.1.8"
21
+ VERSION = "0.1.12"
22
22
  end
data/scone.gemspec CHANGED
@@ -24,18 +24,16 @@ Gem::Specification.new do |spec|
24
24
  spec.authors = ["clivern"]
25
25
  spec.email = ["hello@clivern.com"]
26
26
 
27
- spec.summary = "A Unified SDK for Linux OS Distributions in Ruby."
27
+ spec.summary = "A Ruby SDK for Different Linux Operating System Distributions."
28
28
  spec.description = "A Set of Modules to work with a different Linux Operating System Distributions in Ruby."
29
29
  spec.homepage = "https://github.com/Clivern/Scone"
30
- spec.license = "MIT"
30
+ spec.license = "Apache-2.0"
31
31
  spec.required_ruby_version = ">= 2.6.0"
32
32
 
33
33
  spec.metadata["homepage_uri"] = spec.homepage
34
34
  spec.metadata["source_code_uri"] = "https://github.com/Clivern/Scone"
35
35
  spec.metadata["changelog_uri"] = "https://github.com/Clivern/Scone/blob/main/CHANGELOG.md"
36
36
 
37
- # Specify which files should be added to the gem when it is released.
38
- # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
39
37
  spec.files = Dir.chdir(File.expand_path(__dir__)) do
40
38
  %x(git ls-files -z).split("\x0").reject do |f|
41
39
  (f == __FILE__) || f.match(%r{\A(?:(?:test|spec|features)/|\.(?:git|travis|circleci)|appveyor)})
@@ -46,9 +44,5 @@ Gem::Specification.new do |spec|
46
44
  spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
47
45
  spec.require_paths = ["lib"]
48
46
 
49
- # Uncomment to register a new dependency of your gem
50
- # spec.add_dependency "example-gem", "~> 1.0"
51
-
52
- # For more information and examples about making a new gem, checkout our
53
- # guide at: https://bundler.io/guides/creating_gem.html
47
+ spec.add_dependency("awesome_spawn", "~> 1.5")
54
48
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scone
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.8
4
+ version: 0.1.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - clivern
@@ -9,7 +9,21 @@ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
11
  date: 2021-10-25 00:00:00.000000000 Z
12
- dependencies: []
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: awesome_spawn
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.5'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.5'
13
27
  description: A Set of Modules to work with a different Linux Operating System Distributions
14
28
  in Ruby.
15
29
  email:
@@ -32,13 +46,16 @@ files:
32
46
  - bin/console
33
47
  - bin/setup
34
48
  - cache/.gitignore
49
+ - cache/ifconfig.txt
35
50
  - cache/proc.stat.txt
36
51
  - lib/scone.rb
37
52
  - lib/scone/io/directory.rb
38
53
  - lib/scone/io/file.rb
39
54
  - lib/scone/io/system.rb
40
55
  - lib/scone/platform.rb
56
+ - lib/scone/system.rb
41
57
  - lib/scone/ubuntu/group.rb
58
+ - lib/scone/ubuntu/ip.rb
42
59
  - lib/scone/ubuntu/package.rb
43
60
  - lib/scone/ubuntu/stat.rb
44
61
  - lib/scone/ubuntu/user.rb
@@ -47,7 +64,7 @@ files:
47
64
  - scone.gemspec
48
65
  homepage: https://github.com/Clivern/Scone
49
66
  licenses:
50
- - MIT
67
+ - Apache-2.0
51
68
  metadata:
52
69
  homepage_uri: https://github.com/Clivern/Scone
53
70
  source_code_uri: https://github.com/Clivern/Scone
@@ -70,5 +87,5 @@ requirements: []
70
87
  rubygems_version: 3.1.6
71
88
  signing_key:
72
89
  specification_version: 4
73
- summary: A Unified SDK for Linux OS Distributions in Ruby.
90
+ summary: A Ruby SDK for Different Linux Operating System Distributions.
74
91
  test_files: []