hwid 0.4.0 → 0.4.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/hwid/base.rb +4 -3
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 347ac63e9b96d23e4023bf5aadf258d5c80b5a0246361baeae9fea081287602c
4
- data.tar.gz: 8dca11a19ca1ad94776702b3be99f0c78887e87af3f26a667b0368d8d85c087b
3
+ metadata.gz: f1ddba97eb04afa0e369f6ea6bb0d7fead646b6c659e9248ed199ba32b1d2d51
4
+ data.tar.gz: f1b3efe3f416d71a3bb80febb9106cd04d2259f9d8b966e310e46e3e13df042c
5
5
  SHA512:
6
- metadata.gz: 1124b3a1888b84ecd94cb80b98d192625b3f9bc7d99d3b22bf39eb88e48e618b72e08ab20d6022b07d351a2c6d9627f90ed31764b3b55a04fbe76abcaa50fd13
7
- data.tar.gz: 35fc3b996254f7e2c365bf50121b81da8e6073d26073819515bb0b217cea6653388fbd7769f1e302dbf9ad897bc5856320c10442cd97b38db4fbbcc4b223328d
6
+ metadata.gz: f1dcabb6f5ef8adb5281cdae85a96902b2eb67cf8a882ba242b862d1ad44612b476408f610e061912c1ea6d61d85bfd7aaf5d5cdb19af3d3004aaaad2887b974
7
+ data.tar.gz: e87d5b4d3524d5d02afffc2d4a0ebe01f3fe9553703f30e724f69a6bad924f2d8c232f056b0fc75722b6da21f6a07fafc5c65be7200e245992f6b763cfa1e00e
@@ -30,14 +30,14 @@ module Hwid
30
30
  platform << "x86" if (/x86/ =~ RUBY_PLATFORM) != nil
31
31
  platform << "i686" if (/i686/ =~ RUBY_PLATFORM) != nil
32
32
  platform << "debian" if `uname -a`.include?('Debian')
33
- platform << "microsoft" if `uname -a`.include?('Microsoft')
33
+ platform << "microsoft" if `uname -a`.include?('Microsoft')
34
34
  platform << "ubuntu" if `uname -a`.include?('Ubuntu')
35
35
  platform << "linux" if (/linux/ =~ RUBY_PLATFORM) != nil
36
36
  platform
37
37
  end
38
38
  def systemid
39
39
  platform=get_platform
40
- puts "debug: platform is #{platform} #{RUBY_PLATFORM}"
40
+ puts "debug: platform is #{platform} #{RUBY_PLATFORM}"
41
41
  return get_rasp_id if platform.include?("raspberry")
42
42
  return get_rasp_id if platform.include?("raspberry 2")
43
43
  return get_mac_id if platform.include?("mac")
@@ -63,8 +63,9 @@ module Hwid
63
63
  puts "running windows linux sigh"
64
64
  res=run_cmd("lshw -quiet -class network -disable usb -disable spd | grep -oP '(serial: )\\K.*'")
65
65
  res=res.gsub("0000-","")
66
- res=res.gsum(":","")
66
+ res=res.gsub(":","")
67
67
  res=res.gsub("\n","")
68
+ res=res.gsub(" ","")
68
69
  #res=run_cmd("lshw | grep -A 10 '*-cpu' | grep -oP '(serial: )\\K.*'")
69
70
  #puts "Interim result is #{res.inspect}"
70
71
  res=res.chomp
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hwid
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scott Sproule