appmap 0.37.0 → 0.40.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (211) hide show
  1. checksums.yaml +4 -4
  2. data/.dockerignore +1 -1
  3. data/.rubocop.yml +12 -1
  4. data/.travis.yml +2 -23
  5. data/CHANGELOG.md +24 -0
  6. data/CONTRIBUTING.md +22 -0
  7. data/README.md +79 -50
  8. data/Rakefile +3 -3
  9. data/lib/appmap/class_map.rb +25 -8
  10. data/lib/appmap/config.rb +22 -10
  11. data/lib/appmap/event.rb +16 -1
  12. data/lib/appmap/hook.rb +11 -3
  13. data/lib/appmap/hook/method.rb +18 -12
  14. data/lib/appmap/rails/request_handler.rb +25 -4
  15. data/lib/appmap/railtie.rb +1 -5
  16. data/lib/appmap/trace.rb +18 -7
  17. data/lib/appmap/version.rb +2 -2
  18. data/spec/abstract_controller_base_spec.rb +132 -67
  19. data/spec/fixtures/hook/instance_method.rb +4 -0
  20. data/spec/fixtures/hook/labels.rb +6 -0
  21. data/spec/fixtures/{rails_users_app → rails5_users_app}/.dockerignore +0 -0
  22. data/spec/fixtures/{rails_users_app → rails5_users_app}/.gitignore +0 -0
  23. data/spec/fixtures/{rails_users_app → rails5_users_app}/.rspec +0 -0
  24. data/spec/fixtures/{rails_users_app → rails5_users_app}/.ruby-version +0 -0
  25. data/spec/fixtures/{rails_users_app → rails5_users_app}/Dockerfile +0 -0
  26. data/spec/fixtures/{rails_users_app → rails5_users_app}/Dockerfile.pg +0 -0
  27. data/spec/fixtures/rails5_users_app/Gemfile +50 -0
  28. data/spec/fixtures/{rails_users_app → rails5_users_app}/Rakefile +0 -0
  29. data/spec/fixtures/{rails_users_app → rails5_users_app}/app/controllers/api/users_controller.rb +0 -0
  30. data/spec/fixtures/{rails_users_app → rails5_users_app}/app/controllers/application_controller.rb +0 -0
  31. data/spec/fixtures/{rails4_users_app/app/assets/images → rails5_users_app/app/controllers/concerns}/.keep +0 -0
  32. data/spec/fixtures/{rails_users_app → rails5_users_app}/app/controllers/health_controller.rb +0 -0
  33. data/spec/fixtures/rails5_users_app/app/controllers/users_controller.rb +13 -0
  34. data/spec/fixtures/{rails4_users_app/app/models → rails5_users_app/app/models/activerecord}/user.rb +0 -0
  35. data/spec/fixtures/{rails4_users_app/app/controllers → rails5_users_app/app/models}/concerns/.keep +0 -0
  36. data/spec/fixtures/{rails_users_app → rails5_users_app}/app/models/sequel/user.rb +0 -0
  37. data/spec/fixtures/{rails4_users_app → rails5_users_app}/app/views/layouts/application.html.haml +0 -0
  38. data/spec/fixtures/{rails4_users_app → rails5_users_app}/app/views/users/index.html.haml +0 -0
  39. data/spec/fixtures/rails5_users_app/appmap.yml +4 -0
  40. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/appmap +0 -0
  41. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/byebug +0 -0
  42. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/gli +0 -0
  43. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/htmldiff +0 -0
  44. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/ldiff +0 -0
  45. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/nokogiri +0 -0
  46. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/rackup +0 -0
  47. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/rails +0 -0
  48. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/rake +0 -0
  49. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/rspec +0 -0
  50. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/ruby-parse +0 -0
  51. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/ruby-rewrite +0 -0
  52. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/sequel +0 -0
  53. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/setup +0 -0
  54. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/sprockets +0 -0
  55. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/thor +0 -0
  56. data/spec/fixtures/{rails_users_app → rails5_users_app}/bin/update +0 -0
  57. data/spec/fixtures/{rails_users_app → rails5_users_app}/config.ru +0 -0
  58. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/application.rb +2 -0
  59. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/boot.rb +0 -0
  60. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/credentials.yml.enc +0 -0
  61. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/database.yml +0 -0
  62. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/environment.rb +0 -0
  63. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/environments/development.rb +0 -0
  64. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/environments/production.rb +0 -0
  65. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/environments/test.rb +0 -0
  66. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/initializers/application_controller_renderer.rb +0 -0
  67. data/spec/fixtures/{rails4_users_app → rails5_users_app}/config/initializers/backtrace_silencers.rb +0 -0
  68. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/initializers/cors.rb +0 -0
  69. data/spec/fixtures/{rails4_users_app → rails5_users_app}/config/initializers/filter_parameter_logging.rb +0 -0
  70. data/spec/fixtures/{rails4_users_app → rails5_users_app}/config/initializers/inflections.rb +0 -0
  71. data/spec/fixtures/{rails4_users_app → rails5_users_app}/config/initializers/mime_types.rb +0 -0
  72. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/initializers/record_button.rb +0 -0
  73. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/initializers/wrap_parameters.rb +0 -0
  74. data/spec/fixtures/{rails_users_app → rails5_users_app}/config/locales/en.yml +0 -0
  75. data/spec/fixtures/{rails4_users_app → rails5_users_app}/config/routes.rb +1 -2
  76. data/spec/fixtures/{rails_users_app → rails5_users_app}/create_app +0 -0
  77. data/spec/fixtures/{rails_users_app → rails5_users_app}/db/migrate/20190728211408_create_users.rb +0 -0
  78. data/spec/fixtures/{rails_users_app → rails5_users_app}/db/schema.rb +0 -0
  79. data/spec/fixtures/{rails_users_app → rails5_users_app}/docker-compose.yml +0 -0
  80. data/spec/fixtures/{rails_users_app → rails5_users_app}/features/api_users.feature +0 -0
  81. data/spec/fixtures/{rails_users_app → rails5_users_app}/features/support/env.rb +0 -0
  82. data/spec/fixtures/{rails_users_app → rails5_users_app}/features/support/hooks.rb +0 -0
  83. data/spec/fixtures/{rails_users_app → rails5_users_app}/features/support/steps.rb +0 -0
  84. data/spec/fixtures/{rails4_users_app/app/mailers → rails5_users_app/lib/tasks}/.keep +0 -0
  85. data/spec/fixtures/{rails4_users_app/app/models → rails5_users_app/log}/.keep +0 -0
  86. data/spec/fixtures/{rails_users_app → rails5_users_app}/public/robots.txt +0 -0
  87. data/spec/fixtures/{rails_users_app → rails5_users_app}/spec/controllers/users_controller_api_spec.rb +1 -1
  88. data/spec/fixtures/rails5_users_app/spec/controllers/users_controller_spec.rb +27 -0
  89. data/spec/fixtures/{rails_users_app → rails5_users_app}/spec/models/user_spec.rb +0 -0
  90. data/spec/fixtures/{rails_users_app → rails5_users_app}/spec/rails_helper.rb +0 -0
  91. data/spec/fixtures/{rails4_users_app → rails5_users_app}/spec/spec_helper.rb +0 -0
  92. data/spec/fixtures/{rails_users_app → rails5_users_app}/users_app/.gitignore +0 -0
  93. data/spec/fixtures/rails6_users_app/.dockerignore +1 -0
  94. data/spec/fixtures/rails6_users_app/.gitignore +39 -0
  95. data/spec/fixtures/rails6_users_app/.rspec +1 -0
  96. data/spec/fixtures/rails6_users_app/.ruby-version +1 -0
  97. data/spec/fixtures/{rails4_users_app → rails6_users_app}/Dockerfile +3 -4
  98. data/spec/fixtures/{rails4_users_app → rails6_users_app}/Dockerfile.pg +1 -1
  99. data/spec/fixtures/{rails_users_app → rails6_users_app}/Gemfile +3 -4
  100. data/spec/fixtures/{rails4_users_app → rails6_users_app}/Rakefile +1 -1
  101. data/spec/fixtures/{rails4_users_app → rails6_users_app}/app/controllers/api/users_controller.rb +1 -1
  102. data/spec/fixtures/rails6_users_app/app/controllers/application_controller.rb +2 -0
  103. data/spec/fixtures/{rails4_users_app/app/models → rails6_users_app/app/controllers}/concerns/.keep +0 -0
  104. data/spec/fixtures/{rails4_users_app → rails6_users_app}/app/controllers/health_controller.rb +1 -1
  105. data/spec/fixtures/rails6_users_app/app/controllers/users_controller.rb +13 -0
  106. data/spec/fixtures/{rails_users_app → rails6_users_app}/app/models/activerecord/user.rb +0 -0
  107. data/spec/fixtures/{rails4_users_app/lib/assets → rails6_users_app/app/models/concerns}/.keep +0 -0
  108. data/spec/fixtures/rails6_users_app/app/models/sequel/user.rb +25 -0
  109. data/spec/fixtures/{rails_users_app → rails6_users_app}/app/views/layouts/application.html.haml +0 -0
  110. data/spec/fixtures/{rails_users_app → rails6_users_app}/app/views/users/index.html.haml +0 -0
  111. data/spec/fixtures/rails6_users_app/appmap.yml +5 -0
  112. data/spec/fixtures/rails6_users_app/bin/appmap +29 -0
  113. data/spec/fixtures/rails6_users_app/bin/byebug +29 -0
  114. data/spec/fixtures/rails6_users_app/bin/gli +29 -0
  115. data/spec/fixtures/rails6_users_app/bin/htmldiff +29 -0
  116. data/spec/fixtures/rails6_users_app/bin/ldiff +29 -0
  117. data/spec/fixtures/rails6_users_app/bin/nokogiri +29 -0
  118. data/spec/fixtures/rails6_users_app/bin/rackup +29 -0
  119. data/spec/fixtures/rails6_users_app/bin/rails +4 -0
  120. data/spec/fixtures/rails6_users_app/bin/rake +29 -0
  121. data/spec/fixtures/rails6_users_app/bin/rspec +29 -0
  122. data/spec/fixtures/rails6_users_app/bin/ruby-parse +29 -0
  123. data/spec/fixtures/rails6_users_app/bin/ruby-rewrite +29 -0
  124. data/spec/fixtures/rails6_users_app/bin/sequel +29 -0
  125. data/spec/fixtures/rails6_users_app/bin/setup +25 -0
  126. data/spec/fixtures/rails6_users_app/bin/sprockets +29 -0
  127. data/spec/fixtures/rails6_users_app/bin/thor +29 -0
  128. data/spec/fixtures/rails6_users_app/bin/update +25 -0
  129. data/spec/fixtures/{rails4_users_app → rails6_users_app}/config.ru +2 -1
  130. data/spec/fixtures/rails6_users_app/config/application.rb +53 -0
  131. data/spec/fixtures/rails6_users_app/config/boot.rb +3 -0
  132. data/spec/fixtures/rails6_users_app/config/credentials.yml.enc +1 -0
  133. data/spec/fixtures/{rails4_users_app → rails6_users_app}/config/database.yml +2 -2
  134. data/spec/fixtures/{rails4_users_app → rails6_users_app}/config/environment.rb +1 -1
  135. data/spec/fixtures/rails6_users_app/config/environments/development.rb +40 -0
  136. data/spec/fixtures/{rails4_users_app → rails6_users_app}/config/environments/production.rb +19 -30
  137. data/spec/fixtures/{rails4_users_app → rails6_users_app}/config/environments/test.rb +5 -11
  138. data/spec/fixtures/rails6_users_app/config/initializers/application_controller_renderer.rb +8 -0
  139. data/spec/fixtures/{rails_users_app → rails6_users_app}/config/initializers/backtrace_silencers.rb +0 -0
  140. data/spec/fixtures/rails6_users_app/config/initializers/cors.rb +16 -0
  141. data/spec/fixtures/{rails_users_app → rails6_users_app}/config/initializers/filter_parameter_logging.rb +0 -0
  142. data/spec/fixtures/{rails_users_app → rails6_users_app}/config/initializers/inflections.rb +0 -0
  143. data/spec/fixtures/{rails_users_app → rails6_users_app}/config/initializers/mime_types.rb +0 -0
  144. data/spec/fixtures/rails6_users_app/config/initializers/record_button.rb +3 -0
  145. data/spec/fixtures/{rails4_users_app → rails6_users_app}/config/initializers/wrap_parameters.rb +1 -6
  146. data/spec/fixtures/{rails4_users_app → rails6_users_app}/config/locales/en.yml +10 -0
  147. data/spec/fixtures/{rails_users_app → rails6_users_app}/config/routes.rb +1 -1
  148. data/spec/fixtures/{rails4_users_app → rails6_users_app}/create_app +7 -3
  149. data/spec/fixtures/rails6_users_app/db/migrate/20190728211408_create_users.rb +9 -0
  150. data/spec/fixtures/rails6_users_app/db/schema.rb +23 -0
  151. data/spec/fixtures/{rails4_users_app → rails6_users_app}/docker-compose.yml +3 -1
  152. data/spec/fixtures/rails6_users_app/features/api_users.feature +13 -0
  153. data/spec/fixtures/rails6_users_app/features/support/env.rb +4 -0
  154. data/spec/fixtures/rails6_users_app/features/support/hooks.rb +11 -0
  155. data/spec/fixtures/rails6_users_app/features/support/steps.rb +18 -0
  156. data/spec/fixtures/{rails4_users_app → rails6_users_app}/lib/tasks/.keep +0 -0
  157. data/spec/fixtures/{rails4_users_app → rails6_users_app}/log/.keep +0 -0
  158. data/spec/fixtures/rails6_users_app/public/robots.txt +1 -0
  159. data/spec/fixtures/rails6_users_app/spec/controllers/users_controller_api_spec.rb +29 -0
  160. data/spec/fixtures/rails6_users_app/spec/controllers/users_controller_spec.rb +27 -0
  161. data/spec/fixtures/rails6_users_app/spec/models/user_spec.rb +39 -0
  162. data/spec/fixtures/{rails4_users_app → rails6_users_app}/spec/rails_helper.rb +3 -32
  163. data/spec/fixtures/{rails_users_app → rails6_users_app}/spec/spec_helper.rb +0 -0
  164. data/spec/fixtures/{rails4_users_app → rails6_users_app/users_app}/.gitignore +8 -1
  165. data/spec/hook_spec.rb +111 -57
  166. data/spec/rails_spec_helper.rb +5 -5
  167. data/spec/railtie_spec.rb +31 -32
  168. data/spec/record_sql_rails_pg_spec.rb +62 -63
  169. data/spec/remote_recording_spec.rb +90 -89
  170. data/spec/rspec_feature_metadata_spec.rb +17 -18
  171. data/spec/spec_helper.rb +1 -0
  172. metadata +148 -139
  173. data/spec/abstract_controller4_base_spec.rb +0 -67
  174. data/spec/fixtures/rails4_users_app/.rbenv-gemsets +0 -2
  175. data/spec/fixtures/rails4_users_app/.ruby-version +0 -1
  176. data/spec/fixtures/rails4_users_app/Gemfile +0 -77
  177. data/spec/fixtures/rails4_users_app/README.rdoc +0 -28
  178. data/spec/fixtures/rails4_users_app/app/assets/javascripts/application.js +0 -16
  179. data/spec/fixtures/rails4_users_app/app/assets/stylesheets/application.css +0 -15
  180. data/spec/fixtures/rails4_users_app/app/controllers/application_controller.rb +0 -5
  181. data/spec/fixtures/rails4_users_app/app/controllers/users_controller.rb +0 -5
  182. data/spec/fixtures/rails4_users_app/app/helpers/application_helper.rb +0 -2
  183. data/spec/fixtures/rails4_users_app/appmap.yml +0 -3
  184. data/spec/fixtures/rails4_users_app/bin/rails +0 -9
  185. data/spec/fixtures/rails4_users_app/bin/setup +0 -29
  186. data/spec/fixtures/rails4_users_app/bin/spring +0 -17
  187. data/spec/fixtures/rails4_users_app/config/application.rb +0 -26
  188. data/spec/fixtures/rails4_users_app/config/boot.rb +0 -3
  189. data/spec/fixtures/rails4_users_app/config/environments/development.rb +0 -41
  190. data/spec/fixtures/rails4_users_app/config/initializers/assets.rb +0 -11
  191. data/spec/fixtures/rails4_users_app/config/initializers/cookies_serializer.rb +0 -3
  192. data/spec/fixtures/rails4_users_app/config/initializers/session_store.rb +0 -3
  193. data/spec/fixtures/rails4_users_app/config/initializers/to_time_preserves_timezone.rb +0 -10
  194. data/spec/fixtures/rails4_users_app/config/secrets.yml +0 -22
  195. data/spec/fixtures/rails4_users_app/db/migrate/20191127112304_create_users.rb +0 -10
  196. data/spec/fixtures/rails4_users_app/db/schema.rb +0 -26
  197. data/spec/fixtures/rails4_users_app/db/seeds.rb +0 -7
  198. data/spec/fixtures/rails4_users_app/public/404.html +0 -67
  199. data/spec/fixtures/rails4_users_app/public/422.html +0 -67
  200. data/spec/fixtures/rails4_users_app/public/500.html +0 -66
  201. data/spec/fixtures/rails4_users_app/public/favicon.ico +0 -0
  202. data/spec/fixtures/rails4_users_app/public/robots.txt +0 -5
  203. data/spec/fixtures/rails4_users_app/spec/controllers/users_controller_api_spec.rb +0 -49
  204. data/spec/fixtures/rails4_users_app/test/fixtures/users.yml +0 -9
  205. data/spec/fixtures/rails_users_app/app/controllers/concerns/.keep +0 -0
  206. data/spec/fixtures/rails_users_app/app/controllers/users_controller.rb +0 -5
  207. data/spec/fixtures/rails_users_app/app/models/concerns/.keep +0 -0
  208. data/spec/fixtures/rails_users_app/appmap.yml +0 -3
  209. data/spec/fixtures/rails_users_app/lib/tasks/.keep +0 -0
  210. data/spec/fixtures/rails_users_app/log/.keep +0 -0
  211. data/spec/record_sql_rails4_pg_spec.rb +0 -76
@@ -1,2 +0,0 @@
1
- rails4_users_app
2
-
@@ -1,77 +0,0 @@
1
- source 'https://rubygems.org'
2
- git_source(:github) { |name| "https://github.com/#{name}.git" }
3
-
4
- # Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
5
- gem 'rails', '4.2.11'
6
- gem 'haml-rails'
7
-
8
- # Use postgresql as the database for Active Record
9
- gem 'pg', '~> 0.15'
10
- # Use SCSS for stylesheets
11
- gem 'sass-rails', '~> 5.0'
12
- # Use Uglifier as compressor for JavaScript assets
13
- # gem 'uglifier', '>= 1.3.0'
14
- # Use CoffeeScript for .coffee assets and views
15
- # gem 'coffee-rails', '~> 4.1.0'
16
- # See https://github.com/rails/execjs#readme for more supported runtimes
17
- # gem 'therubyracer', platforms: :ruby
18
-
19
- # Use jquery as the JavaScript library
20
- # gem 'jquery-rails'
21
- # Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
22
- gem 'turbolinks'
23
- # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
24
- gem 'jbuilder', '~> 2.0'
25
- # bundle exec rake doc:rails generates the API under doc/api.
26
- gem 'sdoc', '~> 0.4.0', group: :doc
27
-
28
- # Use ActiveModel has_secure_password
29
- gem 'bcrypt', '~> 3.1.7'
30
-
31
- # Use Unicorn as the app server
32
- # gem 'unicorn'
33
-
34
- # Use Capistrano for deployment
35
- # gem 'capistrano-rails', group: :development
36
-
37
- appmap_path = \
38
- # Support debugging inside the container with volume-mounted source
39
- if File.directory?('/src/appmap-ruby')
40
- '/src/appmap-ruby'
41
- elsif File.exist?('../../../appmap.gemspec')
42
- '../../..'
43
- end
44
-
45
- if appmap_path
46
- # Set the branch parameter, so that 'bundle config local.appmap' will work
47
- appmap_branch = Dir.chdir appmap_path do
48
- `git rev-parse --abbrev-ref HEAD`.strip
49
- end
50
- end
51
-
52
- appmap_options = \
53
- if appmap_path && appmap_branch
54
- { git: appmap_path, branch: appmap_branch }
55
- elsif appmap_path
56
- { path: appmap_path }
57
- else
58
- {}
59
- end.merge(require: %w[appmap appmap/railtie])
60
-
61
- gem 'appmap', appmap_options
62
-
63
- group :development, :test do
64
- gem 'rspec-rails'
65
- gem 'database_cleaner'
66
-
67
- gem 'pry-byebug'
68
- end
69
-
70
- group :development do
71
- # Access an IRB console on exception pages or by using <%= console %> in views
72
- gem 'web-console', '~> 2.0'
73
-
74
- # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
75
- gem 'spring'
76
- end
77
-
@@ -1,28 +0,0 @@
1
- == README
2
-
3
- This README would normally document whatever steps are necessary to get the
4
- application up and running.
5
-
6
- Things you may want to cover:
7
-
8
- * Ruby version
9
-
10
- * System dependencies
11
-
12
- * Configuration
13
-
14
- * Database creation
15
-
16
- * Database initialization
17
-
18
- * How to run the test suite
19
-
20
- * Services (job queues, cache servers, search engines, etc.)
21
-
22
- * Deployment instructions
23
-
24
- * ...
25
-
26
-
27
- Please feel free to use a different markup language if you do not plan to run
28
- <tt>rake doc:app</tt>.
@@ -1,16 +0,0 @@
1
- // This is a manifest file that'll be compiled into application.js, which will include all the files
2
- // listed below.
3
- //
4
- // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
5
- // or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
6
- //
7
- // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
8
- // compiled file.
9
- //
10
- // Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
11
- // about supported directives.
12
- //
13
- //= require jquery
14
- //= require jquery_ujs
15
- //= require turbolinks
16
- //= require_tree .
@@ -1,15 +0,0 @@
1
- /*
2
- * This is a manifest file that'll be compiled into application.css, which will include all the files
3
- * listed below.
4
- *
5
- * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
6
- * or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
7
- *
8
- * You're free to add application-wide styles to this file and they'll appear at the bottom of the
9
- * compiled file so the styles you add here take precedence over styles defined in any styles
10
- * defined in the other CSS/SCSS files in this directory. It is generally better to create a new
11
- * file per style scope.
12
- *
13
- *= require_tree .
14
- *= require_self
15
- */
@@ -1,5 +0,0 @@
1
- class ApplicationController < ActionController::Base
2
- # Prevent CSRF attacks by raising an exception.
3
- # For APIs, you may want to use :null_session instead.
4
- protect_from_forgery with: :exception
5
- end
@@ -1,5 +0,0 @@
1
- class UsersController < ApplicationController
2
- def index
3
- @users = User.all
4
- end
5
- end
@@ -1,2 +0,0 @@
1
- module ApplicationHelper
2
- end
@@ -1,3 +0,0 @@
1
- name: rails4_users_app
2
- packages:
3
- - path: app
@@ -1,9 +0,0 @@
1
- #!/usr/bin/env ruby
2
- begin
3
- load File.expand_path('../spring', __FILE__)
4
- rescue LoadError => e
5
- raise unless e.message.include?('spring')
6
- end
7
- APP_PATH = File.expand_path('../../config/application', __FILE__)
8
- require_relative '../config/boot'
9
- require 'rails/commands'
@@ -1,29 +0,0 @@
1
- #!/usr/bin/env ruby
2
- require 'pathname'
3
-
4
- # path to your application root.
5
- APP_ROOT = Pathname.new File.expand_path('../../', __FILE__)
6
-
7
- Dir.chdir APP_ROOT do
8
- # This script is a starting point to setup your application.
9
- # Add necessary setup steps to this file:
10
-
11
- puts "== Installing dependencies =="
12
- system "gem install bundler --conservative"
13
- system "bundle check || bundle install"
14
-
15
- # puts "\n== Copying sample files =="
16
- # unless File.exist?("config/database.yml")
17
- # system "cp config/database.yml.sample config/database.yml"
18
- # end
19
-
20
- puts "\n== Preparing database =="
21
- system "bin/rake db:setup"
22
-
23
- puts "\n== Removing old logs and tempfiles =="
24
- system "rm -f log/*"
25
- system "rm -rf tmp/cache"
26
-
27
- puts "\n== Restarting application server =="
28
- system "touch tmp/restart.txt"
29
- end
@@ -1,17 +0,0 @@
1
- #!/usr/bin/env ruby
2
-
3
- # This file loads Spring without using Bundler, in order to be fast.
4
- # It gets overwritten when you run the `spring binstub` command.
5
-
6
- unless defined?(Spring)
7
- require 'rubygems'
8
- require 'bundler'
9
-
10
- lockfile = Bundler::LockfileParser.new(Bundler.default_lockfile.read)
11
- spring = lockfile.specs.detect { |spec| spec.name == 'spring' }
12
- if spring
13
- Gem.use_paths Gem.dir, Bundler.bundle_path.to_s, *Gem.path
14
- gem 'spring', spring.version
15
- require 'spring/binstub'
16
- end
17
- end
@@ -1,26 +0,0 @@
1
- require File.expand_path('../boot', __FILE__)
2
-
3
- require 'rails/all'
4
-
5
- # Require the gems listed in Gemfile, including any gems
6
- # you've limited to :test, :development, or :production.
7
- Bundler.require(*Rails.groups)
8
-
9
- module Users
10
- class Application < Rails::Application
11
- # Settings in config/environments/* take precedence over those specified here.
12
- # Application configuration should go into files in config/initializers
13
- # -- all .rb files in that directory are automatically loaded.
14
-
15
- # Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
16
- # Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
17
- # config.time_zone = 'Central Time (US & Canada)'
18
-
19
- # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
20
- # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
21
- # config.i18n.default_locale = :de
22
-
23
- # Do not swallow errors in after_commit/after_rollback callbacks.
24
- config.active_record.raise_in_transactional_callbacks = true
25
- end
26
- end
@@ -1,3 +0,0 @@
1
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
2
-
3
- require 'bundler/setup' # Set up gems listed in the Gemfile.
@@ -1,41 +0,0 @@
1
- Rails.application.configure do
2
- # Settings specified here will take precedence over those in config/application.rb.
3
-
4
- # In the development environment your application's code is reloaded on
5
- # every request. This slows down response time but is perfect for development
6
- # since you don't have to restart the web server when you make code changes.
7
- config.cache_classes = false
8
-
9
- # Do not eager load code on boot.
10
- config.eager_load = false
11
-
12
- # Show full error reports and disable caching.
13
- config.consider_all_requests_local = true
14
- config.action_controller.perform_caching = false
15
-
16
- # Don't care if the mailer can't send.
17
- config.action_mailer.raise_delivery_errors = false
18
-
19
- # Print deprecation notices to the Rails logger.
20
- config.active_support.deprecation = :log
21
-
22
- # Raise an error on page load if there are pending migrations.
23
- config.active_record.migration_error = :page_load
24
-
25
- # Debug mode disables concatenation and preprocessing of assets.
26
- # This option may cause significant delays in view rendering with a large
27
- # number of complex assets.
28
- config.assets.debug = true
29
-
30
- # Asset digests allow you to set far-future HTTP expiration dates on all assets,
31
- # yet still be able to expire them through the digest params.
32
- config.assets.digest = true
33
-
34
- # Adds additional error checking when serving assets at runtime.
35
- # Checks for improperly declared sprockets dependencies.
36
- # Raises helpful error messages.
37
- config.assets.raise_runtime_errors = true
38
-
39
- # Raises error for missing translations
40
- # config.action_view.raise_on_missing_translations = true
41
- end
@@ -1,11 +0,0 @@
1
- # Be sure to restart your server when you modify this file.
2
-
3
- # Version of your assets, change this if you want to expire all your assets.
4
- Rails.application.config.assets.version = '1.0'
5
-
6
- # Add additional assets to the asset load path
7
- # Rails.application.config.assets.paths << Emoji.images_path
8
-
9
- # Precompile additional assets.
10
- # application.js, application.css, and all non-JS/CSS in app/assets folder are already added.
11
- # Rails.application.config.assets.precompile += %w( search.js )
@@ -1,3 +0,0 @@
1
- # Be sure to restart your server when you modify this file.
2
-
3
- Rails.application.config.action_dispatch.cookies_serializer = :json
@@ -1,3 +0,0 @@
1
- # Be sure to restart your server when you modify this file.
2
-
3
- Rails.application.config.session_store :cookie_store, key: '_users_session'
@@ -1,10 +0,0 @@
1
- # Be sure to restart your server when you modify this file.
2
-
3
- # Preserve the timezone of the receiver when calling to `to_time`.
4
- # Ruby 2.4 will change the behavior of `to_time` to preserve the timezone
5
- # when converting to an instance of `Time` instead of the previous behavior
6
- # of converting to the local system timezone.
7
- #
8
- # Rails 5.0 introduced this config option so that apps made with earlier
9
- # versions of Rails are not affected when upgrading.
10
- ActiveSupport.to_time_preserves_timezone = true
@@ -1,22 +0,0 @@
1
- # Be sure to restart your server when you modify this file.
2
-
3
- # Your secret key is used for verifying the integrity of signed cookies.
4
- # If you change this key, all old signed cookies will become invalid!
5
-
6
- # Make sure the secret is at least 30 characters and all random,
7
- # no regular words or you'll be exposed to dictionary attacks.
8
- # You can use `rake secret` to generate a secure secret key.
9
-
10
- # Make sure the secrets in this file are kept private
11
- # if you're sharing your code publicly.
12
-
13
- development:
14
- secret_key_base: ef5e7343ebc4abb9794d3d2d58e8354d1b2ac4db4e6986b73553410d1ab66854fc07a5c38f1d71b39f3a5a683b2c82a6e78def1f189c4314afaef37ed6ad939c
15
-
16
- test:
17
- secret_key_base: 0c784a68e5c6d9aa6e4ecf649b7a36f6b5e4e2ad4f13260c5c852a0fa3ad69b66f653cd7049ae39f104167931e18c8f40ff438b46c63bac2beb6c6b4612acd3d
18
-
19
- # Do not keep production secrets in the repository,
20
- # instead read values from the environment.
21
- production:
22
- secret_key_base: <%= ENV["SECRET_KEY_BASE"] %>
@@ -1,10 +0,0 @@
1
- class CreateUsers < ActiveRecord::Migration
2
- def change
3
- create_table :users do |t|
4
- t.string :login
5
- t.string :password
6
-
7
- t.timestamps null: false
8
- end
9
- end
10
- end
@@ -1,26 +0,0 @@
1
- # encoding: UTF-8
2
- # This file is auto-generated from the current state of the database. Instead
3
- # of editing this file, please use the migrations feature of Active Record to
4
- # incrementally modify your database, and then regenerate this schema definition.
5
- #
6
- # Note that this schema.rb definition is the authoritative source for your
7
- # database schema. If you need to create the application database on another
8
- # system, you should be using db:schema:load, not running all the migrations
9
- # from scratch. The latter is a flawed and unsustainable approach (the more migrations
10
- # you'll amass, the slower it'll run and the greater likelihood for issues).
11
- #
12
- # It's strongly recommended that you check this file into your version control system.
13
-
14
- ActiveRecord::Schema.define(version: 20191127112304) do
15
-
16
- # These are extensions that must be enabled in order to support this database
17
- enable_extension "plpgsql"
18
-
19
- create_table "users", force: :cascade do |t|
20
- t.string "login"
21
- t.string "password"
22
- t.datetime "created_at", null: false
23
- t.datetime "updated_at", null: false
24
- end
25
-
26
- end
@@ -1,7 +0,0 @@
1
- # This file should contain all the record creation needed to seed the database with its default values.
2
- # The data can then be loaded with the rake db:seed (or created alongside the db with db:setup).
3
- #
4
- # Examples:
5
- #
6
- # cities = City.create([{ name: 'Chicago' }, { name: 'Copenhagen' }])
7
- # Mayor.create(name: 'Emanuel', city: cities.first)
@@ -1,67 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>The page you were looking for doesn't exist (404)</title>
5
- <meta name="viewport" content="width=device-width,initial-scale=1">
6
- <style>
7
- body {
8
- background-color: #EFEFEF;
9
- color: #2E2F30;
10
- text-align: center;
11
- font-family: arial, sans-serif;
12
- margin: 0;
13
- }
14
-
15
- div.dialog {
16
- width: 95%;
17
- max-width: 33em;
18
- margin: 4em auto 0;
19
- }
20
-
21
- div.dialog > div {
22
- border: 1px solid #CCC;
23
- border-right-color: #999;
24
- border-left-color: #999;
25
- border-bottom-color: #BBB;
26
- border-top: #B00100 solid 4px;
27
- border-top-left-radius: 9px;
28
- border-top-right-radius: 9px;
29
- background-color: white;
30
- padding: 7px 12% 0;
31
- box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
32
- }
33
-
34
- h1 {
35
- font-size: 100%;
36
- color: #730E15;
37
- line-height: 1.5em;
38
- }
39
-
40
- div.dialog > p {
41
- margin: 0 0 1em;
42
- padding: 1em;
43
- background-color: #F7F7F7;
44
- border: 1px solid #CCC;
45
- border-right-color: #999;
46
- border-left-color: #999;
47
- border-bottom-color: #999;
48
- border-bottom-left-radius: 4px;
49
- border-bottom-right-radius: 4px;
50
- border-top-color: #DADADA;
51
- color: #666;
52
- box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
53
- }
54
- </style>
55
- </head>
56
-
57
- <body>
58
- <!-- This file lives in public/404.html -->
59
- <div class="dialog">
60
- <div>
61
- <h1>The page you were looking for doesn't exist.</h1>
62
- <p>You may have mistyped the address or the page may have moved.</p>
63
- </div>
64
- <p>If you are the application owner check the logs for more information.</p>
65
- </div>
66
- </body>
67
- </html>