rigel 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (7) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGES +3 -0
  3. data/README.md +1 -1
  4. data/bin/rigel +10 -3
  5. data/bug +4 -0
  6. data/lib/rigel/version.rb +1 -1
  7. metadata +4 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a51ebc53ff6ebba1121a65701886f410b87af1d8
4
- data.tar.gz: 6ed01de3dfffdecb5b569fdf9d1a6408603b4162
3
+ metadata.gz: e6544372f1912f6aa30388f92c5b2356e174d70d
4
+ data.tar.gz: a4528ec667bb49357ef52c10f02dda21d018858c
5
5
  SHA512:
6
- metadata.gz: abf87334becd9461edc9e17df9d2f34db8659cf4949e9d06cf4fe2ced96135a6989d9598a986f7f33bea9b5e9f7b37d717784c0319bf82883ec2ddfc33423913
7
- data.tar.gz: 76b39374517db0247a1f805b305e95e62e17e1438f5be858e506f46858f01bc48c9cb92c69a8705f14cc50a3a92b1a71091f5bf1eea15e43ee4090fcafeef9eb
6
+ metadata.gz: 1a49fe0c61b8130914d3d0926b865eb861f3240428a4790393fef3947c3427f9a054d84f46f5d35b904ccb255785196b82dbcd054fd420a16cb34133e5bc5e13
7
+ data.tar.gz: 9d721649f58870eed980ab1fc6b22fc136c629f6109a11fa893bb2ff501e029f8a0e36e0795b9f5ba8da76ac1fa1346ddaa3830b75cc0222e7a8f35092034529
data/CHANGES ADDED
@@ -0,0 +1,3 @@
1
+ 0.0.3
2
+ - using capture2e for calling ri command in place of backticks, due to stderrs coming on screen
3
+ - rescue when doing upcase in bookmarks so that up arrow etc don't give alert about out of char range.
data/README.md CHANGED
@@ -48,7 +48,7 @@ To get ri documentation, you would do
48
48
 
49
49
  If you use any gems for development, e.g. highline or rbcurse-core, use the `--ri` flag while installing the gem (this assumes you've switched off ri and rdocs in your .gemrc).
50
50
 
51
- This gem depends on rbcurse-core
51
+ This gem depends on 'canis'
52
52
 
53
53
  ## Gem name
54
54
 
data/bin/rigel CHANGED
@@ -29,6 +29,7 @@ require 'canis/core/widgets/textpad'
29
29
  require 'canis/core/util/widgetshortcuts'
30
30
  require 'canis/core/util/rcommandwindow'
31
31
  require 'rigel'
32
+ require 'open3'
32
33
 
33
34
 
34
35
  def my_help_text
@@ -129,7 +130,9 @@ end
129
130
  # @param String class or method name to fetch ri info for
130
131
  # @ returns Array of lines, containing ansi format data
131
132
  def get_data str
132
- lines = `ri -f ansi #{str} 2>&1`.gsub('','').split("\n")
133
+ #lines = `ri -f ansi #{str} 2>&1`.gsub('','').split("\n")
134
+ oe, s = Open3.capture2e("ri -f ansi #{str}")
135
+ lines = oe.gsub('','').split("\n")
133
136
  end
134
137
 
135
138
  ##
@@ -192,7 +195,8 @@ end
192
195
  def ask_bookmark ch=nil
193
196
  unless ch
194
197
  ch = @window.getchar
195
- ch = ch.chr.upcase
198
+ ch = ch.chr.upcase rescue nil
199
+ return unless ch
196
200
  end
197
201
  str = $bookmarks[ch.to_sym]
198
202
  if str
@@ -315,6 +319,8 @@ if true
315
319
  ask_classes
316
320
  end
317
321
  @form.bind_key(FFI::NCurses::KEY_F5, 'switch_windows'){ switch_windows }
322
+ # we have bound this to textpad and listb, so perhaps not required here. it is getting triggered
323
+ # two times somehow. It is still calling ask two times
318
324
  @form.bind_key(?', 'select bookmark') do
319
325
  ask_bookmark
320
326
  end
@@ -331,7 +337,7 @@ if true
331
337
  end
332
338
 
333
339
  widget_shortcuts_init
334
- header = app_header "0.0.1", :text_center => "ri Documentation Browser", :text_right =>"rigel" , :name => "header" , :color => :white, :bgcolor => lineback , :attr => :bold
340
+ header = app_header "rigel 0.0.3", :text_center => "ri Documentation Browser", :text_right =>"rigel" , :name => "header" , :color => :white, :bgcolor => lineback , :attr => :bold
335
341
 
336
342
 
337
343
 
@@ -382,6 +388,7 @@ if true
382
388
  ## select class and display riinfo for class
383
389
  }
384
390
  # since keys are added at handle_key, really late, therefore unbind is of no use.
391
+ # This is getting triggered two times ? by form and listb
385
392
  listb.bind_key(?', 'select bookmark') do
386
393
  ask_bookmark
387
394
  end
data/bug ADDED
@@ -0,0 +1,4 @@
1
+ [x] (B) hung after asking for open3, ri was expecting input or something :
2
+ Moved to capture3
3
+ [x] (B) 258 out of range. alert after 'P then down-arrow. : Went to Proc on pressing single-q p then down arrow gave alert
4
+ Bug in canis, fixed.
@@ -1,3 +1,3 @@
1
1
  module Rigel
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rigel
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - kepler
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-07-12 00:00:00.000000000 Z
11
+ date: 2014-08-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -61,12 +61,14 @@ extensions: []
61
61
  extra_rdoc_files: []
62
62
  files:
63
63
  - .gitignore
64
+ - CHANGES
64
65
  - Gemfile
65
66
  - Gemfile.lock
66
67
  - LICENSE
67
68
  - README.md
68
69
  - Rakefile
69
70
  - bin/rigel
71
+ - bug
70
72
  - lib/rigel.rb
71
73
  - lib/rigel/version.rb
72
74
  - rigel.gemspec