jobshop 0.0.10 → 0.0.11

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 682c0ee84f3983c9b0008608ceaf935e8274954f
4
- data.tar.gz: 8ccd26b27cde56d81cdca13d48731bb6f272cf88
3
+ metadata.gz: d5c12cb279c829150853275c704e3370afe0331b
4
+ data.tar.gz: 2b2cb429d021f6723b09874b9f7cf52e6c787b2a
5
5
  SHA512:
6
- metadata.gz: 50bc98ac77ef2d50da1dc9b0cf371f4816f373fe7c3527d58c6c32a86b332ffe92f6cd780231d2c7bd143272b88a5bbda2c7ef763ca01c492d11164b86dbe267
7
- data.tar.gz: a65c6f4e5e1d72c5abb4e995b4c2890aa813d2c8124ccc89d44df9086f0fcd69fed2d5c82a4390c62fd88b0bbad24caf43e45ca2c3f09dd1f6070a01e1a7c565
6
+ metadata.gz: cb6a26a02cab86b8b810bda1bb8d387c556a9b0d8f7c142a7e06fccf1432402ca17c69d7e87c009b9b8d8d50e46bae3f10c29265bf27ab369dc419eb3b66a125
7
+ data.tar.gz: 9b0d72723d6f8a4ead1504eb5ded6b11f392269dac948ece33eaf818f42a7567e995e0d4a61aa74d6c1a87f522e0ab2db41faa5dea34c877f56f74621fe75063
@@ -6,16 +6,11 @@ module Jobshop
6
6
 
7
7
  protect_from_forgery
8
8
 
9
+ before_action :authenticate_user!
10
+
9
11
  # after_action :verify_authorized, except: :index
10
12
  # after_action :verify_policy_scoped, :only => :index
11
13
 
12
- # rescue_from Jobshop::NotAuthenticatedError, with: :not_authenticated
13
-
14
- # def not_authenticated
15
- # flash[:alert] = "Please sign in."
16
- # redirect_to(request.referrer || main_app.root_path)
17
- # end
18
-
19
14
  def layout_for_application
20
15
  if devise_controller? && controller_name == "sessions"
21
16
  "jobshop/unauthenticated"
@@ -4,6 +4,8 @@ module Jobshop
4
4
  class Teams::RegistrationsController < ApplicationController
5
5
  include RegistrationTokenValidation
6
6
 
7
+ skip_before_action :authenticate_user!
8
+
7
9
  def new
8
10
  @registration = ::Jobshop::Registration.new(params)
9
11
  end
@@ -1,8 +1,6 @@
1
1
  Jobshop::Engine.routes.draw do
2
2
  devise_for :users, class_name: "Jobshop::User", module: :devise
3
3
 
4
- get "/dashboard", to: "dashboards#show", as: :user_root
5
-
6
4
  resources :teams, only: [ ] do
7
5
  resource :registration, only: [ :new, :create ],
8
6
  controller: "teams/registrations"
@@ -10,5 +8,5 @@ Jobshop::Engine.routes.draw do
10
8
 
11
9
  get "/about" => redirect("https://jobshop.io"), as: :about
12
10
 
13
- root to: "pages#show", page: "index"
11
+ root to: "dashboards#show"
14
12
  end
@@ -12,6 +12,10 @@ copy_file "boot.rb.tt", "config/boot.rb"
12
12
  remove_file "config/secrets.yml"
13
13
  copy_file "secrets.yml.tt", "config/secrets.yml"
14
14
 
15
+ # Comment out username, password from production group.
16
+ gsub_file "config/database.yml",
17
+ /^([ ]*[^#])(username: .*|password: .*)$/, '\1# \2'
18
+
15
19
  # The db/migrate folder never gets created for the dummy_app so do it manually.
16
20
  unless Dir.exist?("db/migrate")
17
21
  say_status :create, "db/migrate"
@@ -6,7 +6,7 @@ module Jobshop
6
6
  module VERSION
7
7
  MAJOR = 0
8
8
  MINOR = 0
9
- TINY = 10
9
+ TINY = 11
10
10
  PRE = nil
11
11
 
12
12
  CODE_NAME = "bump it up".freeze
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jobshop
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.10
4
+ version: 0.0.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Frank J. Mattia
@@ -180,16 +180,16 @@ dependencies:
180
180
  name: coveralls
181
181
  requirement: !ruby/object:Gem::Requirement
182
182
  requirements:
183
- - - ">="
183
+ - - "~>"
184
184
  - !ruby/object:Gem::Version
185
- version: '0'
185
+ version: '0.8'
186
186
  type: :development
187
187
  prerelease: false
188
188
  version_requirements: !ruby/object:Gem::Requirement
189
189
  requirements:
190
- - - ">="
190
+ - - "~>"
191
191
  - !ruby/object:Gem::Version
192
- version: '0'
192
+ version: '0.8'
193
193
  - !ruby/object:Gem::Dependency
194
194
  name: factory_girl_rails
195
195
  requirement: !ruby/object:Gem::Requirement
@@ -309,7 +309,6 @@ files:
309
309
  - app/controllers/concerns/registration_token_validation.rb
310
310
  - app/controllers/jobshop/application_controller.rb
311
311
  - app/controllers/jobshop/dashboards_controller.rb
312
- - app/controllers/jobshop/pages_controller.rb
313
312
  - app/controllers/jobshop/teams/registrations_controller.rb
314
313
  - app/controllers/jobshop/teams_controller.rb
315
314
  - app/helpers/jobshop/application_helper.rb
@@ -334,7 +333,6 @@ files:
334
333
  - app/views/devise/shared/_links.html.haml
335
334
  - app/views/devise/unlocks/new.html.haml
336
335
  - app/views/jobshop/dashboards/show.html.haml
337
- - app/views/jobshop/pages/index.html.haml
338
336
  - app/views/jobshop/shared/_unauthenticated_layout.html.haml
339
337
  - app/views/jobshop/teams/registrations/new.html.haml
340
338
  - app/views/layouts/jobshop/application.html.haml
@@ -1,29 +0,0 @@
1
- require_dependency "jobshop/application_controller"
2
-
3
- module Jobshop
4
- class PagesController < ApplicationController
5
- layout :layout_for_page
6
-
7
- def show
8
- args = valid_page? ? [ template: page ]
9
- : [ file: "public/404.html", status: :not_found ]
10
- render(*args)
11
- end
12
-
13
- private
14
-
15
- def valid_page?
16
- lookup_context.template_exists?(page)
17
- end
18
-
19
- def page
20
- "jobshop/pages/#{params[:page]}"
21
- end
22
-
23
- def layout_for_page
24
- {
25
- index: "jobshop/unauthenticated"
26
- }.fetch(params[:page].to_sym)
27
- end
28
- end
29
- end
@@ -1,2 +0,0 @@
1
- %main.mdl-layout__content
2
- nothing yet~