just-tmux 0.3.0 → 0.3.1
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
- checksums.yaml.gz.sig +1 -2
- data.tar.gz.sig +0 -0
- data/lib/just-tmux.rb +14 -4
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: ae23d7cde89e644ab4ca57162a4336ac75b87502b0c8c921b6c4aa7982a086d1
|
|
4
|
+
data.tar.gz: d37548d8cbf59e633597fa54f1a3fa241b6cbba94fe069c5201116b5ebd62938
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d6095664aa6a858a4bb4887138734ecc5e8b7ace129d8255822d70a7371bc586f024548bcaf80791d2d87f8b69c730b8851cab07af361af466335d5b5a4cd33e
|
|
7
|
+
data.tar.gz: c957ab2fecd561ac75aa38703c610adc11a3360376a6b894e87af6b21aef6aa22e5ba9a09d5809580ea48b33daae70313ee92f38230cdf335aaebdf9064364c0
|
checksums.yaml.gz.sig
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
3�y;���7������~{ll��-�t��/�sr<�%����R�!l��!�T˸��#�Ѽ�r&����V쒢1�U,�t�J��<�M�!�d�,��`
|
|
1
|
+
#F�*�E2�Y��]�]e���N���~?M�5%oɔ`-ܽKI�hLdϠ�O)7��%9J[4���n
|
data.tar.gz.sig
CHANGED
|
Binary file
|
data/lib/just-tmux.rb
CHANGED
|
@@ -6,6 +6,7 @@ require 'dynarex'
|
|
|
6
6
|
|
|
7
7
|
# revision history
|
|
8
8
|
|
|
9
|
+
# 2019 Nov 06: Bug fix: The sleep variable is now sleepx
|
|
9
10
|
# 2019 Nov 04: Bug fix: The sleep variable is now explicitly set to a float
|
|
10
11
|
# 2018 Aug 05: Minor modification: Changed to using Dynarex#to_a instead of Dynarex#to_h.
|
|
11
12
|
# 2017 Jan 07: Added post_shell to allow a command to execute after the
|
|
@@ -37,7 +38,16 @@ class JustTmux
|
|
|
37
38
|
|
|
38
39
|
puts ('dynarex.summary: ' + dynarex.summary.inspect).debug if @debug
|
|
39
40
|
|
|
40
|
-
shell = dynarex.summary[:shell]
|
|
41
|
+
shell = if dynarex.summary[:shell].nil? or
|
|
42
|
+
dynarex.summary[:shell].empty? then
|
|
43
|
+
|
|
44
|
+
dynarex.summary[:shell] = 'bash'
|
|
45
|
+
|
|
46
|
+
else
|
|
47
|
+
dynarex.summary[:shell]
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
puts 'shell: ' + shell.inspect if @debug
|
|
41
51
|
post_shell = CGI.unescape(dynarex.summary[:post_shell].to_s) || ''
|
|
42
52
|
default_dir = File.expand_path dynarex.summary[:default_dir] || '~'
|
|
43
53
|
session_name = dynarex.summary[:session] || '0'
|
|
@@ -48,16 +58,16 @@ class JustTmux
|
|
|
48
58
|
h = dynarex.to_a.map do |x|
|
|
49
59
|
x[:name] = shell if x[:name].nil? or x[:name].empty?
|
|
50
60
|
x[:dir] = default_dir if x[:dir].nil? or x[:dir].empty?
|
|
51
|
-
x[:
|
|
61
|
+
x[:sleepx] = 0 if x[:sleepx].nil?
|
|
52
62
|
x
|
|
53
63
|
end
|
|
54
64
|
|
|
55
65
|
@to_s = new_session(session_name, h[0][:name], shell, post_shell) +
|
|
56
66
|
send_keys("cd #{h[0][:dir]} && " + h[0][:command]) +
|
|
57
|
-
wait(h[0][:
|
|
67
|
+
wait(h[0][:sleepx]) +
|
|
58
68
|
h[1..-1].map do |x|
|
|
59
69
|
new_window(x[:name], shell, post_shell) +
|
|
60
|
-
send_keys("cd #{x[:dir]} && " + x[:command]) + wait(x[:
|
|
70
|
+
send_keys("cd #{x[:dir]} && " + x[:command]) + wait(x[:sleepx])
|
|
61
71
|
end.join
|
|
62
72
|
|
|
63
73
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: just-tmux
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.3.
|
|
4
|
+
version: 0.3.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- James Robertson
|
|
@@ -35,7 +35,7 @@ cert_chain:
|
|
|
35
35
|
Ggd7b07uuHV4oJkn8z363WdmPI4gdMlsgCfgxTYBmWi7Uj7iXzjH5ANFsUi87+u0
|
|
36
36
|
mnX+WDvwgwFKpX20Y/EbRiKk
|
|
37
37
|
-----END CERTIFICATE-----
|
|
38
|
-
date: 2019-11-
|
|
38
|
+
date: 2019-11-06 00:00:00.000000000 Z
|
|
39
39
|
dependencies:
|
|
40
40
|
- !ruby/object:Gem::Dependency
|
|
41
41
|
name: dynarex
|
metadata.gz.sig
CHANGED
|
Binary file
|