network-utility 1.1.10 → 1.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: 359c2a418cd608485e5294848265847fd25923ac4017f12e9e4d418efe5fcd31
4
- data.tar.gz: 0c1f6c130bdd97c00a91e5ac6b6fe7049dab56a7b8e536da4f0adfd7809efd02
3
+ metadata.gz: 5e147c9d25f2b2508405d772b0da3ff789575a0b04a0a32e1078afa0cd9053ee
4
+ data.tar.gz: 305156de2fdde612946187cf576f01f068ca91a1085f4550cd619a559d47f2ac
5
5
  SHA512:
6
- metadata.gz: 0b193e331aeebc7a27e758c41fbe99417f146e9457c30198ebc387d3ce1affb88c93eaac4e5856d5bd52fd36287e2e3f2485df884410392c99a69750e8bfc419
7
- data.tar.gz: 17f46ace27713d94c39daea5cc5698755865eeb2daf963fccc4e07ab417797a5adf8c745df53177ad07b49514ceba79fb2f8e032a233f12ff18e081511ae7e1d
6
+ metadata.gz: 3e08ff60e1f6a838b8663f845750417cb489ce1e6c062499ec9aad3275d9afdce12599a92cb355ac45726296ce02d9bc2039eeed06a95bce5eee1e842f63c171
7
+ data.tar.gz: 217d2c6545f947b7419aa5af4ed6b72905d1c0406af3b2970a0425126cef66938716d1cb629f7c9dd6703b48baf5e224fd54ead88342966276dbf81afd416c39
data/document/config.md CHANGED
@@ -1053,7 +1053,7 @@ module CR16010H_F
1053
1053
  begin
1054
1054
  raw.split("\n")
1055
1055
  rescue
1056
- raw = braw.force_encoding('GBK').encode('UTF-8')
1056
+ raw = braw.force_encoding('GBK').encode('UTF-8').gsub("\r","")
1057
1057
  end
1058
1058
  cfg = {}
1059
1059
  hostname = guards[0] || raw.split("\n").find{|line|line.include?("sysname ")}.to_s.split("sysname ")[1]
@@ -1090,7 +1090,7 @@ module CR16018_F
1090
1090
  begin
1091
1091
  raw.split("\n")
1092
1092
  rescue
1093
- raw = braw.force_encoding('GBK').encode('UTF-8')
1093
+ raw = braw.force_encoding('GBK').encode('UTF-8').gsub("\r","")
1094
1094
  end
1095
1095
  cfg = {}
1096
1096
  hostname = guards[0] || raw.split("\n").find{|line|line.include?("sysname ")}.to_s.split("sysname ")[1]
@@ -1127,7 +1127,7 @@ module CR19000_20
1127
1127
  begin
1128
1128
  raw.split("\n")
1129
1129
  rescue
1130
- raw = braw.force_encoding('GBK').encode('UTF-8')
1130
+ raw = braw.force_encoding('GBK').encode('UTF-8').gsub("\r","")
1131
1131
  end
1132
1132
  cfg = {}
1133
1133
  hostname = guards[0] || raw.split("\n").find{|line|line.include?("sysname ")}.to_s.split("sysname ")[1]
@@ -68,7 +68,7 @@ module NE40E_X16A
68
68
  # func: 根据一个端口的描述信息,给出其格式化的类型、连接符、端口编号
69
69
  def 端口识别 描述
70
70
  连接符 = ''
71
- type = /100GE|GE|GigabitEthernet|Pos|Ethernet|Eth\-Trunk|Vlanif|Virtual\-Template|NULL|LoopBack|Aux/.match(描述)
71
+ type = /100GE|GE|GigabitEthernet|Global\-VE|Pos|Ethernet|Eth\-Trunk|Ip-Trunk|ServiceIf|Tunnel|Vlanif|Virtual\-Template|NULL|LoopBack|Logic\-Channel|Aux/.match(描述)
72
72
  类型 = type ? type.to_s : '未知类型'
73
73
  port = /(\d+|\/|\.)*(\d+)/.match(描述.split(类型).join)
74
74
  端口 = port ? port.to_s : '未知端口'
data/network.rb CHANGED
@@ -18,5 +18,5 @@
18
18
  ].each{|mod|require mod}
19
19
 
20
20
  module Network
21
- VERSION = '1.1.10'
21
+ VERSION = '1.1.12'
22
22
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: network-utility
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.10
4
+ version: 1.1.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt