qwandry 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/VERSION +1 -1
  2. data/lib/qwandry/launcher.rb +6 -0
  3. metadata +4 -4
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.1
1
+ 0.0.2
@@ -63,6 +63,12 @@ module Qwandry
63
63
  # check against the environment by default.
64
64
  def launch(package, editor=nil)
65
65
  editor ||= @editor || ENV['VISUAL'] || ENV['EDITOR']
66
+
67
+ if (!editor) || (editor =~ /^\s*$/) # if the editor is not set, or is blank, exit with a message:
68
+ puts "Please either set EDITOR or pass in an editor to use"
69
+ exit 1
70
+ end
71
+
66
72
  paths = package.is_a?(String) ? [package] : package.paths
67
73
  system editor, *paths
68
74
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: qwandry
3
3
  version: !ruby/object:Gem::Version
4
- hash: 29
4
+ hash: 27
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 1
10
- version: 0.0.1
9
+ - 2
10
+ version: 0.0.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Adam Sanderson
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-12-07 00:00:00 -08:00
18
+ date: 2010-12-08 00:00:00 -08:00
19
19
  default_executable: qw
20
20
  dependencies: []
21
21