track 0.2.1 → 0.2.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/bin/track +31 -0
  2. data/lib/track/version.rb +1 -1
  3. metadata +14 -12
@@ -0,0 +1,31 @@
1
+ #!/usr/bin/env ruby
2
+ require 'thor'
3
+
4
+ class Track < Thor
5
+
6
+ @@root = File.expand_path('../..', __FILE__)
7
+
8
+ desc 'new PROJECT_NAME', 'create a new track project'
9
+ method_option :force, :aliases => '-f', :desc => 'delete project directory if it exists'
10
+ def new(name)
11
+ if File.exists?(name)
12
+ if options[:force]
13
+ $stdout << "Removing directory '#{name}'.\n"
14
+ FileUtils.rm_rf(name)
15
+ else
16
+ $stdout << "The directory '#{name}' already exists.\n"
17
+ return
18
+ end
19
+ end
20
+ $stdout << "creating new track project #{name}.\n"
21
+ FileUtils.cp_r(File.join(@@root, 'example'), name)
22
+ $stdout << "done.\n\n"
23
+ $stdout << '########################' << "\n\n"
24
+ $stdout << 'do the following to get up and running:' << "\n\n"
25
+ $stdout << "cd #{name}\nbundle install\nbundle exec rackup\n\n"
26
+ $stdout << "open your browser and go to localhost:9292\n\n"
27
+ end
28
+
29
+ end
30
+
31
+ Track.start
@@ -1,3 +1,3 @@
1
1
  module Track
2
- VERSION = '0.2.1'
2
+ VERSION = '0.2.2'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: track
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -13,7 +13,7 @@ date: 2011-12-09 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rack
16
- requirement: &70351917933580 !ruby/object:Gem::Requirement
16
+ requirement: &70240407190380 !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: *70351917933580
24
+ version_requirements: *70240407190380
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: rspec
27
- requirement: &70351917933120 !ruby/object:Gem::Requirement
27
+ requirement: &70240407189920 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ! '>='
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: '0'
33
33
  type: :development
34
34
  prerelease: false
35
- version_requirements: *70351917933120
35
+ version_requirements: *70240407189920
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: rack-test
38
- requirement: &70351917923740 !ruby/object:Gem::Requirement
38
+ requirement: &70240407189480 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: '0'
44
44
  type: :development
45
45
  prerelease: false
46
- version_requirements: *70351917923740
46
+ version_requirements: *70240407189480
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: active_record
49
- requirement: &70351917923320 !ruby/object:Gem::Requirement
49
+ requirement: &70240407188860 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ! '>='
@@ -54,10 +54,10 @@ dependencies:
54
54
  version: '0'
55
55
  type: :development
56
56
  prerelease: false
57
- version_requirements: *70351917923320
57
+ version_requirements: *70240407188860
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: thor
60
- requirement: &70351917922900 !ruby/object:Gem::Requirement
60
+ requirement: &70240407170640 !ruby/object:Gem::Requirement
61
61
  none: false
62
62
  requirements:
63
63
  - - ! '>='
@@ -65,12 +65,13 @@ dependencies:
65
65
  version: '0'
66
66
  type: :development
67
67
  prerelease: false
68
- version_requirements: *70351917922900
68
+ version_requirements: *70240407170640
69
69
  description: Nano framework to build small server applications based on rack and ruby
70
70
  1.9
71
71
  email:
72
72
  - lars.kuhnt@gmail.com
73
- executables: []
73
+ executables:
74
+ - track
74
75
  extensions: []
75
76
  extra_rdoc_files: []
76
77
  files:
@@ -84,6 +85,7 @@ files:
84
85
  - README.md
85
86
  - CHANGELOG.md
86
87
  - ROADMAP.md
88
+ - bin/track
87
89
  homepage: http://github.com/larskuhnt/track
88
90
  licenses: []
89
91
  post_install_message: