ruaur 0.2.4 → 0.2.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/ruaur +5 -2
- data/lib/ruaur/package.rb +2 -3
- metadata +2 -3
- data/lib/string.rb +0 -12
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8a5e2fe6ac79c349b56d1d30959643b0704ca75b
|
4
|
+
data.tar.gz: a71a51dbe47e3be79e673a8f67effbac44e296cc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: de51f7ac7e26fa785e31b9ba8ce2970991eed9c9448c03965349bd4e6f635e788c9f3c3d80a047f289e3c5f35292b075cf13b3e1ad943b30f5f060572a6696f7
|
7
|
+
data.tar.gz: f41d0571e1eee1ad459c90b905b76c21046535a77d428e66538947b940f3366af7d054afc78c8fe4dd3ed26212c105ee20cece82109b5db088f0229767149213
|
data/bin/ruaur
CHANGED
@@ -36,6 +36,8 @@ def parse(args)
|
|
36
36
|
options["nosave"] = false
|
37
37
|
|
38
38
|
parser = OptionParser.new do |opts|
|
39
|
+
opts.summary_width = 17
|
40
|
+
|
39
41
|
opts.banner =
|
40
42
|
"Usage: #{File.basename($0)} <operation> [OPTIONS] [pkgs]"
|
41
43
|
|
@@ -221,12 +223,13 @@ rescue RuAUR::Error => e
|
|
221
223
|
rescue Exception => e
|
222
224
|
$stderr.puts
|
223
225
|
$stderr.puts "Oops! Looks like an error has occured! If the " \
|
224
|
-
"error persists, file a bug at:"
|
226
|
+
"error persists, file a bug at:"
|
225
227
|
$stderr.puts
|
226
228
|
$stderr.puts " https://gitlab.com/mjwhitta/ruaur/issues"
|
227
229
|
$stderr.puts
|
228
230
|
$stderr.puts "Maybe the message below will help. If not, you " \
|
229
|
-
"can use the --verbose flag to get
|
231
|
+
"can use the --verbose flag to get"
|
232
|
+
$stderr.puts "a backtrace."
|
230
233
|
|
231
234
|
$stderr.puts e.message.white.on_red
|
232
235
|
if (options["verbose"])
|
data/lib/ruaur/package.rb
CHANGED
@@ -1,5 +1,4 @@
|
|
1
1
|
require "colorize"
|
2
|
-
require "string"
|
3
2
|
|
4
3
|
class RuAUR::Package
|
5
4
|
attr_accessor :description
|
@@ -120,8 +119,8 @@ class RuAUR::Package
|
|
120
119
|
)
|
121
120
|
|
122
121
|
# Wrap at default minus 4 spaces
|
123
|
-
@description.
|
124
|
-
out.push(" #{
|
122
|
+
@description.scan(/\S.{0,#{76}}\S(?=\s|$)|\S+/).each do |l|
|
123
|
+
out.push(" #{l.strip}")
|
125
124
|
end
|
126
125
|
|
127
126
|
return out.join("\n")
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruaur
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Miles Whittaker
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-03-
|
11
|
+
date: 2016-03-31 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -132,7 +132,6 @@ files:
|
|
132
132
|
- lib/ruaur/error/ruaur_already_running_error.rb
|
133
133
|
- lib/ruaur/package.rb
|
134
134
|
- lib/ruaur/pacman.rb
|
135
|
-
- lib/string.rb
|
136
135
|
homepage: https://mjwhitta.github.io/ruaur
|
137
136
|
licenses:
|
138
137
|
- GPL-3.0
|
data/lib/string.rb
DELETED
@@ -1,12 +0,0 @@
|
|
1
|
-
# Modify String class to allow for rsplit and word wrap
|
2
|
-
class String
|
3
|
-
def rsplit(pattern)
|
4
|
-
ret = rpartition(pattern)
|
5
|
-
ret.delete_at(1)
|
6
|
-
return ret
|
7
|
-
end
|
8
|
-
|
9
|
-
def word_wrap(width = 80)
|
10
|
-
return scan(/\S.{0,#{width}}\S(?=\s|$)|\S+/).join("\n")
|
11
|
-
end
|
12
|
-
end
|