gemedit 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,3 +1,8 @@
1
+ == 0.0.2 2008-03-07
2
+
3
+ * 1 minor enhancement:
4
+ * add -p/--pretend option to show what gem(s) would be edited and with what command
5
+
1
6
  == 0.0.1 2008-02-27
2
7
 
3
8
  * 1 major enhancement:
data/README.txt CHANGED
@@ -1,4 +1,4 @@
1
- gemedit
1
+ gemedit
2
2
  http://gemedit.rubyforge.org/
3
3
  by Lee Marlow
4
4
 
@@ -6,6 +6,8 @@ gemedit
6
6
 
7
7
  Gemedit lets you quickly open up the source for a gem in your favorite editor.
8
8
 
9
+ Looking through other people's code is a great way to learn. I often use it when a gem's RDoc isn't as helpful as I'd like or just want to see how someone put a library together. Gemedit just makes it easier to get to the code.
10
+
9
11
  == INSTALLATION:
10
12
 
11
13
  Gemedit can be installed via RubyGems:
@@ -13,8 +15,27 @@ Gemedit can be installed via RubyGems:
13
15
  $ sudo gem install gemedit
14
16
 
15
17
  If you would like some basic command completion for installed gems add the following to your ~/.bashrc or ~/.profile:
16
- complete -C "/usr/bin/gemedit --complete" gemedit
18
+
19
+ complete -C "/usr/bin/gemedit --complete" gemedit
17
20
 
18
21
  == USAGE:
19
22
 
23
+ If you want to see how gemedit works just install it and run this:
20
24
  $ gemedit gemedit
25
+
26
+ Gemedit tries to use your favorite editor from your <tt>$VISUAL</tt> or <tt>$EDITOR</tt> environment variable. It will fall back to <em>everyone's</em> favorite editor: *vi*. You can specify the editor with the <tt>-e/--editor</tt> switch. Run this to view the source for +rake+ in TextMate[http://macromates.com]:
27
+ $ gemedit -e mate rake
28
+
29
+ And of course, help is available:
30
+ $ gemedit -h
31
+ $ gemedit --help
32
+
33
+ == DOCUMENTATION:
34
+
35
+ There isn't much more to document than what is on this page, but feel free to browse the RDoc[http://gemedit.rubyforge.org/rdoc/]. Or checkout the Rubyforge project page here[http://rubyforge.org/projects/gemedit/].
36
+
37
+ == SOURCE REPOSITORY:
38
+
39
+ The source is currently on github[http://github.com/]. You can browse through it at http://github.com/lmarlow/gemedit or pull it down and play with it yourself with
40
+
41
+ $ git clone git://github.com/lmarlow/gemedit.git
@@ -13,6 +13,7 @@ require 'optparse'
13
13
 
14
14
  OPTIONS = {
15
15
  :verbose => false,
16
+ :pretend => false,
16
17
  :editor => ENV['VISUAL'] || ENV['EDITOR'] || 'vi'
17
18
  }
18
19
 
@@ -24,9 +25,12 @@ Usage: #{File.basename($0)} GEM_NAME...
24
25
 
25
26
  Options are:
26
27
  BANNER
27
- opts.separator ""
28
28
  opts.on("-e", "--editor=EDITOR", String,
29
29
  "The editor to open the gems with", "Default: #{OPTIONS[:editor]}") { |editor| OPTIONS[:editor] = editor }
30
+ opts.on("-p", "--pretend",
31
+ "Shows what command would be run without running it", "Turns on verbose logging", "Default: #{OPTIONS[:pretend]}") { |pretend|
32
+ OPTIONS[:pretend] = OPTIONS[:verbose] = true
33
+ }
30
34
  opts.on("-v", "--verbose",
31
35
  "Enable verbose logging", "Default: #{OPTIONS[:verbose]}") { |verbose| OPTIONS[:verbose] = true }
32
36
  opts.on("-h", "--help",
@@ -79,7 +83,7 @@ if gems.size > 0
79
83
  end
80
84
  cmd = "#{OPTIONS[:editor]} #{paths.join(' ')}"
81
85
  puts "Running `#{cmd}`" if OPTIONS[:verbose]
82
- exec cmd
86
+ exec cmd unless OPTIONS[:pretend]
83
87
  else
84
88
  puts "No gems found for editing"
85
89
  end
@@ -2,7 +2,7 @@ module Gemedit #:nodoc:
2
2
  module VERSION #:nodoc:
3
3
  MAJOR = 0
4
4
  MINOR = 0
5
- TINY = 1
5
+ TINY = 2
6
6
 
7
7
  STRING = [MAJOR, MINOR, TINY].join('.')
8
8
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gemedit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lee Marlow
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2008-02-28 00:00:00 -07:00
12
+ date: 2008-03-07 00:00:00 -07:00
13
13
  default_executable:
14
14
  dependencies: []
15
15