ro_thor 4.6.0 → 4.6.4
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 +4 -4
- data/lib/ro_thor.rb +12 -11
- data/lib/ro_thor/array.rb +1 -0
- data/lib/ro_thor/helper.rb +3 -2
- data/lib/ro_thor/ro_file.rb +3 -1
- data/lib/ro_thor/string.rb +7 -0
- metadata +5 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c9849c3848afee6af24a77627d2c230240d56392b16318fd2c57944a8259955c
|
4
|
+
data.tar.gz: c9bb5a620807f7bed997feb964d667c999f66c4de0d8ef4d923c87c4c3c044c5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 02d7f6ff434be07eb629fa70a09bebef9417ad2195fbf0fae14ce9454b193ff48b24ee023b8aed42dccf6cb6ee3bc39439ae252bbec4a2df9f8875119b46e65e
|
7
|
+
data.tar.gz: cf137cd3a67e40e8c760417e7fd87171eb98ddb135c1fc4cdfa85e2ff60e5a0e355ea2045cb98a6083b07b3a38b59a5a1fc092a4317d4ad6cfb772ae7c718e23
|
data/lib/ro_thor.rb
CHANGED
@@ -7,6 +7,7 @@ require 'ro_thor/base'
|
|
7
7
|
require 'ro_thor/sh'
|
8
8
|
require 'ro_thor/ro_file'
|
9
9
|
require 'ro_thor/array'
|
10
|
+
require 'ro_thor/string'
|
10
11
|
require 'ro_thor/helper'
|
11
12
|
require 'ro_thor/ro_err'
|
12
13
|
require 'ro_thor/http'
|
@@ -39,6 +40,10 @@ class RoThor < Thor
|
|
39
40
|
desc(str, "")
|
40
41
|
end
|
41
42
|
|
43
|
+
def st(*args)
|
44
|
+
start(args)
|
45
|
+
end
|
46
|
+
|
42
47
|
def create_command(*args, &blk)
|
43
48
|
if @usage.nil?
|
44
49
|
return
|
@@ -46,10 +51,6 @@ class RoThor < Thor
|
|
46
51
|
super
|
47
52
|
end
|
48
53
|
|
49
|
-
def st(*args, &blk)
|
50
|
-
start(args)
|
51
|
-
end
|
52
|
-
|
53
54
|
def lamb(*args, &blk)
|
54
55
|
lambda(*args, &blk)
|
55
56
|
end
|
@@ -140,13 +141,13 @@ class RoThor < Thor
|
|
140
141
|
|
141
142
|
def toggle_win(win_name)
|
142
143
|
wins = begin
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
144
|
+
shsu("xdotool search --onlyvisible #{win_name}").split("\n")
|
145
|
+
rescue RoThor::Sh::Err => e
|
146
|
+
out(e)
|
147
|
+
out(e.backtrace.join("\n"))
|
148
|
+
sleep(0.5)
|
149
|
+
retry
|
150
|
+
end
|
150
151
|
if wins.size > 0
|
151
152
|
sh "xdotool windowactivate #{wins.first.strip}"
|
152
153
|
end
|
data/lib/ro_thor/array.rb
CHANGED
data/lib/ro_thor/helper.rb
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
require_relative 'base'
|
2
|
+
require_relative 'string'
|
2
3
|
|
3
4
|
class RoThor
|
4
5
|
module Helper
|
@@ -11,8 +12,8 @@ class RoThor
|
|
11
12
|
shsu("xclip -sel clip -o")
|
12
13
|
end
|
13
14
|
|
14
|
-
def to_md5(
|
15
|
-
|
15
|
+
def to_md5(str)
|
16
|
+
str.md5
|
16
17
|
end
|
17
18
|
|
18
19
|
def in_pj(pj_name, *args, &blk)
|
data/lib/ro_thor/ro_file.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ro_thor
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.6.
|
4
|
+
version: 4.6.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ''
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-08-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|
@@ -110,6 +110,7 @@ files:
|
|
110
110
|
- lib/ro_thor/ro_file.rb
|
111
111
|
- lib/ro_thor/sh.rb
|
112
112
|
- lib/ro_thor/ssh.rb
|
113
|
+
- lib/ro_thor/string.rb
|
113
114
|
- spec/lib/core_ext/array_spec.rb
|
114
115
|
- spec/lib/ro_cmd/thor/dp_spec.rb
|
115
116
|
- spec/lib/ro_thor/ro_err_spec.rb
|
@@ -140,10 +141,10 @@ signing_key:
|
|
140
141
|
specification_version: 4
|
141
142
|
summary: ''
|
142
143
|
test_files:
|
143
|
-
- spec/spec_helper.rb
|
144
144
|
- spec/lib/ro_cmd/thor/dp_spec.rb
|
145
|
-
- spec/lib/core_ext/array_spec.rb
|
146
145
|
- spec/lib/ro_thor/ssh_spec.rb
|
147
146
|
- spec/lib/ro_thor/ro_err_spec.rb
|
147
|
+
- spec/lib/core_ext/array_spec.rb
|
148
148
|
- spec/rails_helper.rb
|
149
|
+
- spec/spec_helper.rb
|
149
150
|
- spec/mysql/my.cnf
|