my_bloody_valentine 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +4 -0
- data/Gemfile.lock +85 -0
- data/README.md +4 -0
- data/bin/val +14 -0
- data/core.rb +0 -0
- data/lib/my_bloody_valentine/app_builder.rb +29 -0
- data/lib/my_bloody_valentine/generators/app_generator.rb +21 -0
- data/lib/my_bloody_valentine/version.rb +3 -0
- data/my_bloody_valentine.gemspec +28 -0
- data/templates/Gemfile_additions +20 -0
- metadata +90 -0
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,85 @@
|
|
1
|
+
GEM
|
2
|
+
remote: https://rubygems.org/
|
3
|
+
specs:
|
4
|
+
actionmailer (3.2.8)
|
5
|
+
actionpack (= 3.2.8)
|
6
|
+
mail (~> 2.4.4)
|
7
|
+
actionpack (3.2.8)
|
8
|
+
activemodel (= 3.2.8)
|
9
|
+
activesupport (= 3.2.8)
|
10
|
+
builder (~> 3.0.0)
|
11
|
+
erubis (~> 2.7.0)
|
12
|
+
journey (~> 1.0.4)
|
13
|
+
rack (~> 1.4.0)
|
14
|
+
rack-cache (~> 1.2)
|
15
|
+
rack-test (~> 0.6.1)
|
16
|
+
sprockets (~> 2.1.3)
|
17
|
+
activemodel (3.2.8)
|
18
|
+
activesupport (= 3.2.8)
|
19
|
+
builder (~> 3.0.0)
|
20
|
+
activerecord (3.2.8)
|
21
|
+
activemodel (= 3.2.8)
|
22
|
+
activesupport (= 3.2.8)
|
23
|
+
arel (~> 3.0.2)
|
24
|
+
tzinfo (~> 0.3.29)
|
25
|
+
activeresource (3.2.8)
|
26
|
+
activemodel (= 3.2.8)
|
27
|
+
activesupport (= 3.2.8)
|
28
|
+
activesupport (3.2.8)
|
29
|
+
i18n (~> 0.6)
|
30
|
+
multi_json (~> 1.0)
|
31
|
+
arel (3.0.2)
|
32
|
+
builder (3.0.3)
|
33
|
+
erubis (2.7.0)
|
34
|
+
hike (1.2.1)
|
35
|
+
i18n (0.6.1)
|
36
|
+
journey (1.0.4)
|
37
|
+
json (1.7.5)
|
38
|
+
mail (2.4.4)
|
39
|
+
i18n (>= 0.4.0)
|
40
|
+
mime-types (~> 1.16)
|
41
|
+
treetop (~> 1.4.8)
|
42
|
+
mime-types (1.19)
|
43
|
+
multi_json (1.3.6)
|
44
|
+
polyglot (0.3.3)
|
45
|
+
rack (1.4.1)
|
46
|
+
rack-cache (1.2)
|
47
|
+
rack (>= 0.4)
|
48
|
+
rack-ssl (1.3.2)
|
49
|
+
rack
|
50
|
+
rack-test (0.6.1)
|
51
|
+
rack (>= 1.0)
|
52
|
+
rails (3.2.8)
|
53
|
+
actionmailer (= 3.2.8)
|
54
|
+
actionpack (= 3.2.8)
|
55
|
+
activerecord (= 3.2.8)
|
56
|
+
activeresource (= 3.2.8)
|
57
|
+
activesupport (= 3.2.8)
|
58
|
+
bundler (~> 1.0)
|
59
|
+
railties (= 3.2.8)
|
60
|
+
railties (3.2.8)
|
61
|
+
actionpack (= 3.2.8)
|
62
|
+
activesupport (= 3.2.8)
|
63
|
+
rack-ssl (~> 1.3.2)
|
64
|
+
rake (>= 0.8.7)
|
65
|
+
rdoc (~> 3.4)
|
66
|
+
thor (>= 0.14.6, < 2.0)
|
67
|
+
rake (0.9.2.2)
|
68
|
+
rdoc (3.12)
|
69
|
+
json (~> 1.4)
|
70
|
+
sprockets (2.1.3)
|
71
|
+
hike (~> 1.2)
|
72
|
+
rack (~> 1.0)
|
73
|
+
tilt (~> 1.1, != 1.3.0)
|
74
|
+
thor (0.16.0)
|
75
|
+
tilt (1.3.3)
|
76
|
+
treetop (1.4.10)
|
77
|
+
polyglot
|
78
|
+
polyglot (>= 0.3.1)
|
79
|
+
tzinfo (0.3.33)
|
80
|
+
|
81
|
+
PLATFORMS
|
82
|
+
ruby
|
83
|
+
|
84
|
+
DEPENDENCIES
|
85
|
+
rails
|
data/README.md
ADDED
data/bin/val
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#! /usr/bin/env ruby
|
2
|
+
|
3
|
+
require File.expand_path(File.join('..', 'lib', 'my_bloody_valentine', 'generators', 'app_generator'), File.dirname(__FILE__))
|
4
|
+
require File.expand_path(File.join('..', 'lib', 'my_bloody_valentine', 'app_builder'), File.dirname(__FILE__))
|
5
|
+
|
6
|
+
# Template stuff
|
7
|
+
|
8
|
+
templates_root = File.expand_path(File.join("..", "templates"), File.dirname(__FILE__))
|
9
|
+
Suspenders::AppGenerator.source_root templates_root
|
10
|
+
Suspenders::AppGenerator.source_paths << Rails::Generators::AppGenerator.source_root << templates_root
|
11
|
+
|
12
|
+
# Other stuff
|
13
|
+
|
14
|
+
Suspenders::AppGenerator.start
|
data/core.rb
ADDED
File without changes
|
@@ -0,0 +1,29 @@
|
|
1
|
+
module MyBloodyValentine
|
2
|
+
class AppBuilder < Rails::AppBuilder
|
3
|
+
def remove_public_index
|
4
|
+
remove_file 'public/index.html'
|
5
|
+
end
|
6
|
+
|
7
|
+
def initialize_on_precompile
|
8
|
+
inject_into_file 'config/application.rb',
|
9
|
+
"\n config.assets.initialize_on_precompile = false",
|
10
|
+
:after => 'config.assets.enabled = true'
|
11
|
+
end
|
12
|
+
|
13
|
+
def use_postgres_config_template
|
14
|
+
template 'postgresql_database.yml.erb', 'config/database.yml',
|
15
|
+
:force => true
|
16
|
+
end
|
17
|
+
|
18
|
+
def add_custom_gems
|
19
|
+
additions_path = find_in_source_paths 'Gemfile_additions'
|
20
|
+
new_gems = File.open(additions_path).read
|
21
|
+
inject_into_file 'Gemfile', "\n #{new_gems}",
|
22
|
+
:after => /gem 'jquery-rails'/
|
23
|
+
end
|
24
|
+
|
25
|
+
def setup_staging_environment
|
26
|
+
run 'cp config/environments/production.rb config/environments/staging.rb'
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
@@ -0,0 +1,21 @@
|
|
1
|
+
module MyBloodyValentine
|
2
|
+
class AppGenerator < Rails::Generators::AppGenerator
|
3
|
+
|
4
|
+
def my_bloody_valentine_customiziation
|
5
|
+
invoke :add_custom_gems
|
6
|
+
|
7
|
+
end
|
8
|
+
|
9
|
+
def setup_staging_environment
|
10
|
+
say "Setting up the stagin environment"
|
11
|
+
build :setup_staging_environment
|
12
|
+
end
|
13
|
+
|
14
|
+
def setup_development_environment
|
15
|
+
say "Setting Up Development environment"
|
16
|
+
build :enable_factory_girl_syntax
|
17
|
+
end
|
18
|
+
|
19
|
+
|
20
|
+
end
|
21
|
+
end
|
@@ -0,0 +1,28 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
$:.push File.expand_path("../lib", __FILE__)
|
3
|
+
require "my_bloody_valentine/version"
|
4
|
+
|
5
|
+
Gem::Specification.new do |s|
|
6
|
+
s.name = 'my_bloody_valentine'
|
7
|
+
s.version = MyBloodyValentine::VERSION
|
8
|
+
s.date = Date.today.strftime('%Y-%m-%d')
|
9
|
+
s.authors = ["cookiebatch"]
|
10
|
+
s.email = 'keymint1498@gmail.com'
|
11
|
+
s.homepage = "https://github.com/cookiebatch/my_bloody_valentine"
|
12
|
+
|
13
|
+
s.summary = "Generate a Rails app"
|
14
|
+
s.description = <<-HERE
|
15
|
+
MyBloodyValentine is a base Rails project
|
16
|
+
HERE
|
17
|
+
|
18
|
+
s.files = `git ls-files`.split("\n").
|
19
|
+
reject { |file| file =~ /^\./ }.
|
20
|
+
reject { |file| file =~ /^(rdoc|pkg)/ }
|
21
|
+
s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
|
22
|
+
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
23
|
+
s.require_paths = ["lib"]
|
24
|
+
|
25
|
+
|
26
|
+
s.add_dependency 'rails', '3.2.8'
|
27
|
+
s.add_dependency 'bundler', '>= 1.1'
|
28
|
+
end
|
@@ -0,0 +1,20 @@
|
|
1
|
+
group :development do
|
2
|
+
gem 'foreman'
|
3
|
+
gem "rspec-rails"
|
4
|
+
gem 'growl'
|
5
|
+
end
|
6
|
+
|
7
|
+
|
8
|
+
group :test do
|
9
|
+
gem "rspec-rails"
|
10
|
+
gem "spork"
|
11
|
+
gem "factory_girl_rails"
|
12
|
+
gem "capybara"
|
13
|
+
gem "guard-rspec"
|
14
|
+
gem "guard-spork"
|
15
|
+
gem 'growl'
|
16
|
+
gem "timecop"
|
17
|
+
gem "vcr"
|
18
|
+
end
|
19
|
+
|
20
|
+
gem 'capistrano'
|
metadata
ADDED
@@ -0,0 +1,90 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: my_bloody_valentine
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
prerelease:
|
6
|
+
platform: ruby
|
7
|
+
authors:
|
8
|
+
- cookiebatch
|
9
|
+
autorequire:
|
10
|
+
bindir: bin
|
11
|
+
cert_chain: []
|
12
|
+
date: 2012-09-17 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: rails
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
|
+
none: false
|
18
|
+
requirements:
|
19
|
+
- - '='
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: 3.2.8
|
22
|
+
type: :runtime
|
23
|
+
prerelease: false
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - '='
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: 3.2.8
|
30
|
+
- !ruby/object:Gem::Dependency
|
31
|
+
name: bundler
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
33
|
+
none: false
|
34
|
+
requirements:
|
35
|
+
- - ! '>='
|
36
|
+
- !ruby/object:Gem::Version
|
37
|
+
version: '1.1'
|
38
|
+
type: :runtime
|
39
|
+
prerelease: false
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ! '>='
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: '1.1'
|
46
|
+
description: ! 'MyBloodyValentine is a base Rails project
|
47
|
+
|
48
|
+
'
|
49
|
+
email: keymint1498@gmail.com
|
50
|
+
executables:
|
51
|
+
- val
|
52
|
+
extensions: []
|
53
|
+
extra_rdoc_files: []
|
54
|
+
files:
|
55
|
+
- Gemfile
|
56
|
+
- Gemfile.lock
|
57
|
+
- README.md
|
58
|
+
- bin/val
|
59
|
+
- core.rb
|
60
|
+
- lib/my_bloody_valentine/app_builder.rb
|
61
|
+
- lib/my_bloody_valentine/generators/app_generator.rb
|
62
|
+
- lib/my_bloody_valentine/version.rb
|
63
|
+
- my_bloody_valentine-0.0.1.gem
|
64
|
+
- my_bloody_valentine.gemspec
|
65
|
+
- templates/Gemfile_additions
|
66
|
+
homepage: https://github.com/cookiebatch/my_bloody_valentine
|
67
|
+
licenses: []
|
68
|
+
post_install_message:
|
69
|
+
rdoc_options: []
|
70
|
+
require_paths:
|
71
|
+
- lib
|
72
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
74
|
+
requirements:
|
75
|
+
- - ! '>='
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: '0'
|
78
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
79
|
+
none: false
|
80
|
+
requirements:
|
81
|
+
- - ! '>='
|
82
|
+
- !ruby/object:Gem::Version
|
83
|
+
version: '0'
|
84
|
+
requirements: []
|
85
|
+
rubyforge_project:
|
86
|
+
rubygems_version: 1.8.23
|
87
|
+
signing_key:
|
88
|
+
specification_version: 3
|
89
|
+
summary: Generate a Rails app
|
90
|
+
test_files: []
|