jackdempsey-beet 0.0.7 → 0.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/VERSION +1 -1
- data/beet.gemspec +2 -1
- data/bin/beet +2 -2
- data/lib/beet/recipes/passenger/vhost.rb +16 -0
- data/lib/beet/recipes/rails/authlogic.rb +11 -11
- metadata +2 -1
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.8
|
data/beet.gemspec
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = %q{beet}
|
5
|
-
s.version = "0.0.
|
5
|
+
s.version = "0.0.8"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["Jack Dempsey"]
|
@@ -31,6 +31,7 @@ Gem::Specification.new do |s|
|
|
31
31
|
"lib/beet/interaction.rb",
|
32
32
|
"lib/beet/logger.rb",
|
33
33
|
"lib/beet/rails.rb",
|
34
|
+
"lib/beet/recipes/passenger/vhost.rb",
|
34
35
|
"lib/beet/recipes/rails/authlogic.rb",
|
35
36
|
"lib/beet/recipes/rails/clean_files.rb",
|
36
37
|
"lib/beet/recipes/rails/db/mysql.rb",
|
data/bin/beet
CHANGED
@@ -31,8 +31,8 @@ class BeetRunner < Thor
|
|
31
31
|
|
32
32
|
desc 'just_recipe', "when you just need a recipe"
|
33
33
|
method_options :recipes => :optional, :gems => :optional
|
34
|
-
def just_recipe
|
35
|
-
executor = Beet::Executor.new(
|
34
|
+
def just_recipe(app_name='.')
|
35
|
+
executor = Beet::Executor.new(app_name, options)
|
36
36
|
executor.start
|
37
37
|
end
|
38
38
|
|
@@ -0,0 +1,16 @@
|
|
1
|
+
in_root do
|
2
|
+
file "#{project_name}.local.vhost.conf" do
|
3
|
+
%{
|
4
|
+
<VirtualHost *:80>
|
5
|
+
ServerName #{project_name}.local
|
6
|
+
DocumentRoot "#{root}/public"
|
7
|
+
RackEnv development
|
8
|
+
<directory "#{root}/public">
|
9
|
+
Order allow,deny
|
10
|
+
Allow from all
|
11
|
+
</directory>
|
12
|
+
</VirtualHost>
|
13
|
+
}.strip
|
14
|
+
end
|
15
|
+
run "sudo mv ./#{project_name}.local.vhost.conf /etc/apache2/passenger_pane_vhosts"
|
16
|
+
end
|
@@ -3,7 +3,7 @@ file "app/models/user_session.rb" do
|
|
3
3
|
class UserSession < Authlogic::Session::Base
|
4
4
|
logout_on_timeout true # default is false
|
5
5
|
end
|
6
|
-
}
|
6
|
+
}.strip
|
7
7
|
end
|
8
8
|
|
9
9
|
file "app/models/user.rb" do
|
@@ -13,7 +13,7 @@ class User < ActiveRecord::Base
|
|
13
13
|
c.logged_in_timeout = 10.minutes # default is 10.minutes
|
14
14
|
end
|
15
15
|
end
|
16
|
-
}
|
16
|
+
}.strip
|
17
17
|
end
|
18
18
|
|
19
19
|
file "app/controllers/user_sessions_controller.rb" do
|
@@ -42,7 +42,7 @@ class UserSessionsController < ApplicationController
|
|
42
42
|
redirect_back_or_default new_user_session_url
|
43
43
|
end
|
44
44
|
end
|
45
|
-
}
|
45
|
+
}.strip
|
46
46
|
end
|
47
47
|
|
48
48
|
|
@@ -62,7 +62,7 @@ file "app/views/user_sessions/new.html.erb" do
|
|
62
62
|
<br />
|
63
63
|
<%= f.submit "Login" %>
|
64
64
|
<% end %>
|
65
|
-
}
|
65
|
+
}.strip
|
66
66
|
end
|
67
67
|
|
68
68
|
# Setup some routes
|
@@ -121,7 +121,7 @@ class ApplicationController < ActionController::Base
|
|
121
121
|
session[:return_to] = nil
|
122
122
|
end
|
123
123
|
end
|
124
|
-
}
|
124
|
+
}.strip
|
125
125
|
end
|
126
126
|
|
127
127
|
file "app/controllers/users_controller.rb" do
|
@@ -162,7 +162,7 @@ class UsersController < ApplicationController
|
|
162
162
|
end
|
163
163
|
end
|
164
164
|
end
|
165
|
-
}
|
165
|
+
}.strip
|
166
166
|
end
|
167
167
|
|
168
168
|
file "app/views/users/_form.html.erb" do
|
@@ -175,7 +175,7 @@ file "app/views/users/_form.html.erb" do
|
|
175
175
|
<br />
|
176
176
|
<%= form.label :password_confirmation %><br />
|
177
177
|
<%= form.password_field :password_confirmation %><br />
|
178
|
-
}
|
178
|
+
}.strip
|
179
179
|
end
|
180
180
|
|
181
181
|
file "app/views/users/edit.html.erb" do
|
@@ -189,7 +189,7 @@ file "app/views/users/edit.html.erb" do
|
|
189
189
|
<% end %>
|
190
190
|
|
191
191
|
<br /><%= link_to "My Profile", account_path %>
|
192
|
-
}
|
192
|
+
}.strip
|
193
193
|
end
|
194
194
|
|
195
195
|
file "app/views/users/new.html.erb" do
|
@@ -201,7 +201,7 @@ file "app/views/users/new.html.erb" do
|
|
201
201
|
<%= render :partial => "form", :object => f %>
|
202
202
|
<%= f.submit "Register" %>
|
203
203
|
<% end %>
|
204
|
-
}
|
204
|
+
}.strip
|
205
205
|
end
|
206
206
|
|
207
207
|
file "app/views/users/show.html.erb" do
|
@@ -243,7 +243,7 @@ file "app/views/users/show.html.erb" do
|
|
243
243
|
|
244
244
|
|
245
245
|
<%= link_to 'Edit', edit_account_path %>
|
246
|
-
}
|
246
|
+
}.strip
|
247
247
|
end
|
248
248
|
|
249
249
|
# can't rely on internal rails migration generation, so we do it this way
|
@@ -279,7 +279,7 @@ class BeetAuthlogicCreateUser < ActiveRecord::Migration
|
|
279
279
|
drop_table :users
|
280
280
|
end
|
281
281
|
end
|
282
|
-
}
|
282
|
+
}.strip
|
283
283
|
end
|
284
284
|
|
285
285
|
gem 'authlogic'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jackdempsey-beet
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jack Dempsey
|
@@ -48,6 +48,7 @@ files:
|
|
48
48
|
- lib/beet/interaction.rb
|
49
49
|
- lib/beet/logger.rb
|
50
50
|
- lib/beet/rails.rb
|
51
|
+
- lib/beet/recipes/passenger/vhost.rb
|
51
52
|
- lib/beet/recipes/rails/authlogic.rb
|
52
53
|
- lib/beet/recipes/rails/clean_files.rb
|
53
54
|
- lib/beet/recipes/rails/db/mysql.rb
|