re-org 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/re-org/command.rb +11 -2
- data/lib/re-org/version.rb +1 -1
- metadata +6 -6
data/lib/re-org/command.rb
CHANGED
@@ -67,7 +67,7 @@ module ReOrg
|
|
67
67
|
puts "- #{File.basename(template)}\t(default)"
|
68
68
|
end
|
69
69
|
|
70
|
-
|
70
|
+
templates_dirs.each do |template_dir|
|
71
71
|
if Dir.exists?(template_dir)
|
72
72
|
Dir["#{template_dir}/*"].each do |template|
|
73
73
|
puts "- #{File.basename(template)}\t(found at #{template_dir}/)"
|
@@ -114,7 +114,7 @@ module ReOrg
|
|
114
114
|
|
115
115
|
private
|
116
116
|
def find_template(template)
|
117
|
-
|
117
|
+
templates_dirs.each do |template_dir|
|
118
118
|
if Dir.exists?(template_dir) and File.exists?(File.join(template_dir, "#{template}.org"))
|
119
119
|
return File.expand_path(File.join(template_dir, "#{template}.org"))
|
120
120
|
end
|
@@ -122,5 +122,14 @@ module ReOrg
|
|
122
122
|
|
123
123
|
return File.expand_path(File.join('templates', "#{template}.org"), File.dirname(__FILE__))
|
124
124
|
end
|
125
|
+
|
126
|
+
def templates_dirs
|
127
|
+
tdir = CUSTOM_TEMPLATES_DIRS
|
128
|
+
if ENV['ORG_TEMPLATES_DIR']
|
129
|
+
tdir << File.expand_path(ENV['ORG_TEMPLATES_DIR'])
|
130
|
+
end
|
131
|
+
|
132
|
+
tdir
|
133
|
+
end
|
125
134
|
end
|
126
135
|
end
|
data/lib/re-org/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: re-org
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-12-
|
12
|
+
date: 2013-12-19 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: docopt
|
16
|
-
requirement: &
|
16
|
+
requirement: &70351242424800 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: '0'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *70351242424800
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: org-ruby
|
27
|
-
requirement: &
|
27
|
+
requirement: &70351242424380 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,7 +32,7 @@ dependencies:
|
|
32
32
|
version: '0'
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *70351242424380
|
36
36
|
description: An Org mode file organizer
|
37
37
|
email:
|
38
38
|
- waldemar.quevedo@gmail.com
|