termcity 0.4.1 → 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/termcity/formatters/iterm2.rb +8 -4
- data/lib/termcity/formatters/simple.rb +7 -1
- data/lib/termcity/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f1fe6111612429630e0d33e5812ca88f64a64277
|
4
|
+
data.tar.gz: 2ddf23d6ed8c78cc5f0430a7cd8f1e3bb45d6613
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3e427dd57a1a013ee9b51654b05ad08e5ba64c7291e4e6eb65aa93bf2f148f1808eafa7730bb64a08fc3352e7ae1b9d54efe3c78add9042fa598ca8afd98ce53
|
7
|
+
data.tar.gz: 4bb7a19d404fc7a2a1d5f84e31b951f5a33b83f285cbba8dd9ec6a2b97792cb0aae3a322902f19a2073505b7c682590c5832ce010abc6877bf27a6866b7f0488
|
@@ -13,8 +13,12 @@ module Termcity
|
|
13
13
|
def format(summary)
|
14
14
|
rows = summary.builds.map do |raw:, status:|
|
15
15
|
cols = []
|
16
|
-
|
17
|
-
|
16
|
+
|
17
|
+
text = simple_formatter.status_string(status) { |t|
|
18
|
+
"#{linkify(t, raw.fetch("web_url"))}#{" "*(10-t.length)}"
|
19
|
+
}
|
20
|
+
|
21
|
+
cols << linkify(text, raw.fetch("web_url"))
|
18
22
|
cols << raw.fetch("build_type")
|
19
23
|
cols.join(" ")
|
20
24
|
end
|
@@ -22,8 +26,8 @@ module Termcity
|
|
22
26
|
@io.puts(simple_formatter.summarize(summary, rows))
|
23
27
|
end
|
24
28
|
|
25
|
-
def linkify(url)
|
26
|
-
"\e]8;;#{url}\
|
29
|
+
def linkify(text, url)
|
30
|
+
"\e]8;;#{url}\a#{text}\e]8;;\a"
|
27
31
|
end
|
28
32
|
end
|
29
33
|
end
|
@@ -46,7 +46,13 @@ module Termcity
|
|
46
46
|
name = "#{name},q" if re_enqueued
|
47
47
|
color = COLORS[type]
|
48
48
|
|
49
|
-
|
49
|
+
text =
|
50
|
+
if block_given?
|
51
|
+
yield(name)
|
52
|
+
else
|
53
|
+
name.ljust(10)
|
54
|
+
end
|
55
|
+
colorize(text, color)
|
50
56
|
end
|
51
57
|
|
52
58
|
def summarize(summary, rows)
|
data/lib/termcity/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: termcity
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pete Kinnecom
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-10-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|