ribhu 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/README.md +5 -3
  2. data/bin/ribhu +6 -4
  3. data/ribhu.gemspec +1 -1
  4. metadata +3 -3
data/README.md CHANGED
@@ -7,7 +7,7 @@ Classes on the left list, and details on the right.
7
7
  You may press Enter on a class to see its documention. Pressing ENTER over a method in the right will
8
8
  fetch its details.
9
9
 
10
- You may mark classes with an upper case alphabet (vim style) and access them directly using single-quote.
10
+ You may mark classes with an upper case alphabet (vim style by pressing 'm' in the left list) and access them directly using single-quote.
11
11
  Several classes have been bookmarked such as Array, String, Hash, File. You may place more in a file named "~/.ribhu.conf" in the form:
12
12
 
13
13
  $bookmark[:Z] = "Zlib"
@@ -17,8 +17,10 @@ from the conf file as:
17
17
 
18
18
  $visited.concat %w{Abbrev GC ARGF}
19
19
 
20
- Pressing Alt-c and type in any class or method or portion. If `ri` does not return data or returns
21
- choices, a popup will allows selection of choices.
20
+ Pressing Alt-c ('ask-class') and type in any class or method or portion. If `ri` does not return data or returns
21
+ choices, a popup will allows selection of choices. If you have used the Alt-c already, pressing Alt-h inside the ask-class popup will show history of previous searches.
22
+
23
+ In the right window, pressing Alt-m will allow selection of methods from a popup. Space and ENTER select, use j/k/gg/G for navigation, or 'f' following by a char to go to the first or next method starting with that char. e.g. pressing 'fm' jumps to 'match' for String.
22
24
 
23
25
  Search through the current window using "/". You may use "Alt-h" to access history (previous searches).
24
26
 
data/bin/ribhu CHANGED
@@ -106,7 +106,7 @@ end
106
106
  def ask_classes
107
107
  format="rdoc"
108
108
  str = get_string_with_history("Enter a class name: ")
109
- if str != ""
109
+ if str && str != ""
110
110
  lines = `ri -f #{format} #{str}`.split("\n")
111
111
  if lines.size == 0
112
112
  alert "Nothing came through for #{str}"
@@ -301,7 +301,7 @@ if true
301
301
  listb.bind_key(?m) {
302
302
  str = listb.text
303
303
  ch = get_string("Enter character as shortcut for #{str}")
304
- if ch != ""
304
+ if ch && ch != ""
305
305
  add_bookmark ch[0], str
306
306
  end
307
307
  ## select class and display riinfo for class
@@ -362,8 +362,10 @@ if true
362
362
  alert "No instance methods found"
363
363
  end
364
364
  if ix
365
- values = lines[ix..-1]
366
- ix = popuplist(values)
365
+ values = lines[ix+2..-1]
366
+ values = values.collect { |x| x.strip }
367
+ #ix = popuplist(values)
368
+ ix = popuplist(values, :title => " Methods ", :bgcolor => :blue, :color => :white)
367
369
  if ix
368
370
  meth = values[ix].strip
369
371
  display_text "#{kl}.#{meth}"
data/ribhu.gemspec CHANGED
@@ -5,7 +5,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
5
5
 
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = "ribhu"
8
- spec.version = "0.0.3"
8
+ spec.version = "0.0.4"
9
9
  spec.authors = ["Rahul Kumar"]
10
10
  spec.email = ["sentinel1879@gmail.com"]
11
11
  spec.description = %q{ri documentation browser using ncurses}
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ribhu
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -89,7 +89,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
89
89
  version: '0'
90
90
  segments:
91
91
  - 0
92
- hash: 13658087095020374
92
+ hash: -2514237222482059383
93
93
  required_rubygems_version: !ruby/object:Gem::Requirement
94
94
  none: false
95
95
  requirements:
@@ -98,7 +98,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
98
98
  version: '0'
99
99
  segments:
100
100
  - 0
101
- hash: 13658087095020374
101
+ hash: -2514237222482059383
102
102
  requirements: []
103
103
  rubyforge_project:
104
104
  rubygems_version: 1.8.25