rails_magic_renamer 2.0.0.pre.alpha

Sign up to get free protection for your applications and to get access to all the features.
Files changed (164) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +2 -0
  3. data/.ruby-version +1 -0
  4. data/.travis.yml +6 -0
  5. data/CHANGELOG +4 -0
  6. data/Gemfile +4 -0
  7. data/Gemfile.lock +173 -0
  8. data/Guardfile +11 -0
  9. data/Manifest +8 -0
  10. data/README.md +59 -0
  11. data/ROADMAP.md +60 -0
  12. data/Rakefile +2 -0
  13. data/lib/rails_magic_renamer.rb +343 -0
  14. data/lib/rails_magic_renamer/exceptions.rb +35 -0
  15. data/lib/rails_magic_renamer/version.rb +3 -0
  16. data/rails_magic_renamer.gemspec +36 -0
  17. data/spec/rails_helper.rb +26 -0
  18. data/spec/rails_magic_renamer_spec.rb +22 -0
  19. data/spec/spec_helper.rb +17 -0
  20. data/spec/support/sample_app_rails_4/.gitignore +19 -0
  21. data/spec/support/sample_app_rails_4/.rspec +2 -0
  22. data/spec/support/sample_app_rails_4/Gemfile +58 -0
  23. data/spec/support/sample_app_rails_4/Gemfile.lock +249 -0
  24. data/spec/support/sample_app_rails_4/Guardfile +53 -0
  25. data/spec/support/sample_app_rails_4/LICENSE +21 -0
  26. data/spec/support/sample_app_rails_4/README.md +25 -0
  27. data/spec/support/sample_app_rails_4/README.nitrous.md +20 -0
  28. data/spec/support/sample_app_rails_4/Rakefile +6 -0
  29. data/spec/support/sample_app_rails_4/app/assets/images/rails.png +0 -0
  30. data/spec/support/sample_app_rails_4/app/assets/javascripts/application.js +17 -0
  31. data/spec/support/sample_app_rails_4/app/assets/javascripts/sessions.js.coffee +3 -0
  32. data/spec/support/sample_app_rails_4/app/assets/javascripts/static_pages.js.coffee +3 -0
  33. data/spec/support/sample_app_rails_4/app/assets/javascripts/users.js.coffee +3 -0
  34. data/spec/support/sample_app_rails_4/app/assets/stylesheets/application.css +13 -0
  35. data/spec/support/sample_app_rails_4/app/assets/stylesheets/custom.css.scss +246 -0
  36. data/spec/support/sample_app_rails_4/app/assets/stylesheets/sessions.css.scss +3 -0
  37. data/spec/support/sample_app_rails_4/app/assets/stylesheets/static_pages.css.scss +3 -0
  38. data/spec/support/sample_app_rails_4/app/assets/stylesheets/users.css.scss +3 -0
  39. data/spec/support/sample_app_rails_4/app/controllers/application_controller.rb +6 -0
  40. data/spec/support/sample_app_rails_4/app/controllers/concerns/.keep +0 -0
  41. data/spec/support/sample_app_rails_4/app/controllers/microposts_controller.rb +31 -0
  42. data/spec/support/sample_app_rails_4/app/controllers/relationships_controller.rb +21 -0
  43. data/spec/support/sample_app_rails_4/app/controllers/sessions_controller.rb +21 -0
  44. data/spec/support/sample_app_rails_4/app/controllers/static_pages_controller.rb +18 -0
  45. data/spec/support/sample_app_rails_4/app/controllers/users_controller.rb +80 -0
  46. data/spec/support/sample_app_rails_4/app/helpers/application_helper.rb +12 -0
  47. data/spec/support/sample_app_rails_4/app/helpers/sessions_helper.rb +49 -0
  48. data/spec/support/sample_app_rails_4/app/helpers/static_pages_helper.rb +2 -0
  49. data/spec/support/sample_app_rails_4/app/helpers/users_helper.rb +10 -0
  50. data/spec/support/sample_app_rails_4/app/mailers/.keep +0 -0
  51. data/spec/support/sample_app_rails_4/app/models/.keep +0 -0
  52. data/spec/support/sample_app_rails_4/app/models/comment.rb +5 -0
  53. data/spec/support/sample_app_rails_4/app/models/concerns/.keep +0 -0
  54. data/spec/support/sample_app_rails_4/app/models/micropost.rb +14 -0
  55. data/spec/support/sample_app_rails_4/app/models/organisation.rb +3 -0
  56. data/spec/support/sample_app_rails_4/app/models/relationship.rb +6 -0
  57. data/spec/support/sample_app_rails_4/app/models/user.rb +57 -0
  58. data/spec/support/sample_app_rails_4/app/models/user_comment.rb +5 -0
  59. data/spec/support/sample_app_rails_4/app/views/layouts/_footer.html.erb +13 -0
  60. data/spec/support/sample_app_rails_4/app/views/layouts/_header.html.erb +31 -0
  61. data/spec/support/sample_app_rails_4/app/views/layouts/_shim.html.erb +3 -0
  62. data/spec/support/sample_app_rails_4/app/views/layouts/application.html.erb +22 -0
  63. data/spec/support/sample_app_rails_4/app/views/microposts/_micropost.html.erb +11 -0
  64. data/spec/support/sample_app_rails_4/app/views/relationships/create.js.erb +2 -0
  65. data/spec/support/sample_app_rails_4/app/views/relationships/destroy.js.erb +2 -0
  66. data/spec/support/sample_app_rails_4/app/views/sessions/new.html.erb +19 -0
  67. data/spec/support/sample_app_rails_4/app/views/shared/_error_messages.html.erb +12 -0
  68. data/spec/support/sample_app_rails_4/app/views/shared/_feed.html.erb +6 -0
  69. data/spec/support/sample_app_rails_4/app/views/shared/_feed_item.html.erb +15 -0
  70. data/spec/support/sample_app_rails_4/app/views/shared/_micropost_form.html.erb +7 -0
  71. data/spec/support/sample_app_rails_4/app/views/shared/_stats.html.erb +15 -0
  72. data/spec/support/sample_app_rails_4/app/views/shared/_user_info.html.erb +12 -0
  73. data/spec/support/sample_app_rails_4/app/views/static_pages/about.html.erb +8 -0
  74. data/spec/support/sample_app_rails_4/app/views/static_pages/contact.html.erb +6 -0
  75. data/spec/support/sample_app_rails_4/app/views/static_pages/help.html.erb +8 -0
  76. data/spec/support/sample_app_rails_4/app/views/static_pages/home.html.erb +34 -0
  77. data/spec/support/sample_app_rails_4/app/views/static_pages/show.html.erb +0 -0
  78. data/spec/support/sample_app_rails_4/app/views/users/_follow.html.erb +5 -0
  79. data/spec/support/sample_app_rails_4/app/views/users/_follow_form.html.erb +9 -0
  80. data/spec/support/sample_app_rails_4/app/views/users/_unfollow.html.erb +5 -0
  81. data/spec/support/sample_app_rails_4/app/views/users/_user.html.erb +8 -0
  82. data/spec/support/sample_app_rails_4/app/views/users/edit.html.erb +27 -0
  83. data/spec/support/sample_app_rails_4/app/views/users/index.html.erb +10 -0
  84. data/spec/support/sample_app_rails_4/app/views/users/new.html.erb +24 -0
  85. data/spec/support/sample_app_rails_4/app/views/users/show.html.erb +24 -0
  86. data/spec/support/sample_app_rails_4/app/views/users/show_follow.html.erb +30 -0
  87. data/spec/support/sample_app_rails_4/bin/bundle +3 -0
  88. data/spec/support/sample_app_rails_4/bin/rails +4 -0
  89. data/spec/support/sample_app_rails_4/bin/rake +4 -0
  90. data/spec/support/sample_app_rails_4/config.ru +4 -0
  91. data/spec/support/sample_app_rails_4/config/application.rb +31 -0
  92. data/spec/support/sample_app_rails_4/config/boot.rb +4 -0
  93. data/spec/support/sample_app_rails_4/config/cucumber.yml +8 -0
  94. data/spec/support/sample_app_rails_4/config/database.yml +12 -0
  95. data/spec/support/sample_app_rails_4/config/environment.rb +7 -0
  96. data/spec/support/sample_app_rails_4/config/environments/development.rb +27 -0
  97. data/spec/support/sample_app_rails_4/config/environments/production.rb +79 -0
  98. data/spec/support/sample_app_rails_4/config/environments/test.rb +39 -0
  99. data/spec/support/sample_app_rails_4/config/initializers/backtrace_silencers.rb +7 -0
  100. data/spec/support/sample_app_rails_4/config/initializers/filter_parameter_logging.rb +4 -0
  101. data/spec/support/sample_app_rails_4/config/initializers/inflections.rb +16 -0
  102. data/spec/support/sample_app_rails_4/config/initializers/mime_types.rb +5 -0
  103. data/spec/support/sample_app_rails_4/config/initializers/secret_token.rb +22 -0
  104. data/spec/support/sample_app_rails_4/config/initializers/session_store.rb +3 -0
  105. data/spec/support/sample_app_rails_4/config/initializers/wrap_parameters.rb +14 -0
  106. data/spec/support/sample_app_rails_4/config/locales/en.yml +23 -0
  107. data/spec/support/sample_app_rails_4/config/routes.rb +17 -0
  108. data/spec/support/sample_app_rails_4/db/development.sqlite3 +0 -0
  109. data/spec/support/sample_app_rails_4/db/migrate/20130311191400_create_users.rb +10 -0
  110. data/spec/support/sample_app_rails_4/db/migrate/20130311194153_add_index_to_users_email.rb +5 -0
  111. data/spec/support/sample_app_rails_4/db/migrate/20130311201841_add_password_digest_to_users.rb +5 -0
  112. data/spec/support/sample_app_rails_4/db/migrate/20130314184954_add_remember_token_to_users.rb +6 -0
  113. data/spec/support/sample_app_rails_4/db/migrate/20130315015932_add_admin_to_users.rb +5 -0
  114. data/spec/support/sample_app_rails_4/db/migrate/20130315175534_create_microposts.rb +11 -0
  115. data/spec/support/sample_app_rails_4/db/migrate/20130315230445_create_relationships.rb +13 -0
  116. data/spec/support/sample_app_rails_4/db/migrate/20160424113439_create_comments.rb +8 -0
  117. data/spec/support/sample_app_rails_4/db/migrate/20160424113451_create_user_comments.rb +8 -0
  118. data/spec/support/sample_app_rails_4/db/migrate/20160424114701_create_organisations.rb +8 -0
  119. data/spec/support/sample_app_rails_4/db/migrate/20160424114727_add_organisation_id_to_users.rb +5 -0
  120. data/spec/support/sample_app_rails_4/db/schema.rb +67 -0
  121. data/spec/support/sample_app_rails_4/db/seeds.rb +7 -0
  122. data/spec/support/sample_app_rails_4/db/test.sqlite3 +0 -0
  123. data/spec/support/sample_app_rails_4/factory_girl.rb +7 -0
  124. data/spec/support/sample_app_rails_4/features/signing_in.feature +13 -0
  125. data/spec/support/sample_app_rails_4/features/step_definitions/authentication_steps.rb +30 -0
  126. data/spec/support/sample_app_rails_4/features/support/env.rb +59 -0
  127. data/spec/support/sample_app_rails_4/lib/assets/.keep +0 -0
  128. data/spec/support/sample_app_rails_4/lib/tasks/.keep +0 -0
  129. data/spec/support/sample_app_rails_4/lib/tasks/cucumber.rake +65 -0
  130. data/spec/support/sample_app_rails_4/lib/tasks/sample_data.rake +42 -0
  131. data/spec/support/sample_app_rails_4/log/.keep +0 -0
  132. data/spec/support/sample_app_rails_4/public/404.html +27 -0
  133. data/spec/support/sample_app_rails_4/public/422.html +26 -0
  134. data/spec/support/sample_app_rails_4/public/500.html +26 -0
  135. data/spec/support/sample_app_rails_4/public/assets/application-4962059d8f80f9bb096692bacc29c4e8.css +5091 -0
  136. data/spec/support/sample_app_rails_4/public/assets/application-4962059d8f80f9bb096692bacc29c4e8.css.gz +0 -0
  137. data/spec/support/sample_app_rails_4/public/assets/application-eeb856e3fe2c8f879c91d0e81d59cb40.js +12952 -0
  138. data/spec/support/sample_app_rails_4/public/assets/application-eeb856e3fe2c8f879c91d0e81d59cb40.js.gz +0 -0
  139. data/spec/support/sample_app_rails_4/public/assets/glyphicons-halflings-c806376f05e4ccabe2c5315a8e95667c.png +0 -0
  140. data/spec/support/sample_app_rails_4/public/assets/glyphicons-halflings-white-62b67d9edee3db90d18833087f848d6e.png +0 -0
  141. data/spec/support/sample_app_rails_4/public/assets/manifest-802de9eb1c853769101852422b620883.json +1 -0
  142. data/spec/support/sample_app_rails_4/public/assets/rails-231a680f23887d9dd70710ea5efd3c62.png +0 -0
  143. data/spec/support/sample_app_rails_4/public/favicon.ico +0 -0
  144. data/spec/support/sample_app_rails_4/public/robots.txt +5 -0
  145. data/spec/support/sample_app_rails_4/script/cucumber +10 -0
  146. data/spec/support/sample_app_rails_4/spec/controllers/relationships_controller_spec.rb +42 -0
  147. data/spec/support/sample_app_rails_4/spec/factories.rb +17 -0
  148. data/spec/support/sample_app_rails_4/spec/features/authentication_pages_spec.rb +155 -0
  149. data/spec/support/sample_app_rails_4/spec/features/micropost_pages_spec.rb +45 -0
  150. data/spec/support/sample_app_rails_4/spec/features/static_pages_spec.rb +64 -0
  151. data/spec/support/sample_app_rails_4/spec/features/user_pages_spec.rb +239 -0
  152. data/spec/support/sample_app_rails_4/spec/helpers/application_helper_spec.rb +18 -0
  153. data/spec/support/sample_app_rails_4/spec/models/comments_spec.rb +5 -0
  154. data/spec/support/sample_app_rails_4/spec/models/micropost_spec.rb +30 -0
  155. data/spec/support/sample_app_rails_4/spec/models/organisation_spec.rb +5 -0
  156. data/spec/support/sample_app_rails_4/spec/models/relationship_spec.rb +36 -0
  157. data/spec/support/sample_app_rails_4/spec/models/user_comments_spec.rb +5 -0
  158. data/spec/support/sample_app_rails_4/spec/models/user_spec.rb +108 -0
  159. data/spec/support/sample_app_rails_4/spec/spec_helper.rb +57 -0
  160. data/spec/support/sample_app_rails_4/spec/support/utilities.rb +21 -0
  161. data/spec/support/sample_app_rails_4/vendor/assets/javascripts/.keep +0 -0
  162. data/spec/support/sample_app_rails_4/vendor/assets/stylesheets/.keep +0 -0
  163. data/tasks/rspec.rake +4 -0
  164. metadata +534 -0
@@ -0,0 +1,53 @@
1
+ # A sample Guardfile
2
+ # More info at https://github.com/guard/guard#readme
3
+ require 'active_support/inflector'
4
+
5
+ guard 'spork', :cucumber_env => { 'RAILS_ENV' => 'test' },
6
+ :rspec_env => { 'RAILS_ENV' => 'test' } do
7
+ watch('config/application.rb')
8
+ watch('config/environment.rb')
9
+ watch('config/environments/test.rb')
10
+ watch(%r{^config/initializers/.+\.rb$})
11
+ watch('Gemfile')
12
+ watch('Gemfile.lock')
13
+ watch('spec/spec_helper.rb') { :rspec }
14
+ watch('test/test_helper.rb') { :test_unit }
15
+ watch(%r{features/support/}) { :cucumber }
16
+ end
17
+
18
+ guard 'rspec', all_after_pass: false, cli: '--drb' do
19
+ watch(%r{^spec/.+_spec\.rb$})
20
+ watch(%r{^lib/(.+)\.rb$}) { |m| "spec/lib/#{m[1]}_spec.rb" }
21
+ watch('spec/spec_helper.rb') { "spec" }
22
+
23
+ # Rails example
24
+ watch(%r{^app/(.+)\.rb$}) { |m| "spec/#{m[1]}_spec.rb" }
25
+ watch(%r{^app/(.*)(\.erb|\.haml)$}) { |m| "spec/#{m[1]}#{m[2]}_spec.rb" }
26
+ watch(%r{^app/controllers/(.+)_(controller)\.rb$}) { |m| ["spec/routing/#{m[1]}_routing_spec.rb", "spec/#{m[2]}s/#{m[1]}_#{m[2]}_spec.rb", "spec/acceptance/#{m[1]}_spec.rb"] }
27
+ watch(%r{^spec/support/(.+)\.rb$}) { "spec" }
28
+ watch('config/routes.rb') { "spec/routing" }
29
+ watch('app/controllers/application_controller.rb') { "spec/controllers" }
30
+
31
+ # Capybara features specs
32
+ watch(%r{^app/views/(.+)/.*\.(erb|haml)$}) { |m| "spec/features/#{m[1]}_spec.rb" }
33
+
34
+ # Turnip features and steps
35
+ watch(%r{^spec/acceptance/(.+)\.feature$})
36
+ watch(%r{^spec/acceptance/steps/(.+)_steps\.rb$}) { |m| Dir[File.join("**/#{m[1]}.feature")][0] || 'spec/acceptance' }
37
+
38
+ # Custom Rails Tutorial specs
39
+ watch(%r{^app/controllers/(.+)_(controller)\.rb$}) do |m|
40
+ ["spec/routing/#{m[1]}_routing_spec.rb",
41
+ "spec/#{m[2]}s/#{m[1]}_#{m[2]}_spec.rb",
42
+ "spec/acceptance/#{m[1]}_spec.rb",
43
+ (m[1][/_pages/] ? "spec/requests/#{m[1]}_spec.rb" :
44
+ "spec/requests/#{m[1].singularize}_pages_spec.rb")]
45
+ end
46
+ watch(%r{^app/views/(.+)/}) do |m|
47
+ (m[1][/_pages/] ? "spec/requests/#{m[1]}_spec.rb" :
48
+ "spec/requests/#{m[1].singularize}_pages_spec.rb")
49
+ end
50
+ watch(%r{^app/controllers/sessions_controller\.rb$}) do |m|
51
+ "spec/requests/authentication_pages_spec.rb"
52
+ end
53
+ end
@@ -0,0 +1,21 @@
1
+ The MIT License
2
+
3
+ Copyright (c) 2013 Michael Hartl
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
@@ -0,0 +1,25 @@
1
+ # Ruby on Rails Tutorial: sample application
2
+
3
+ This is the sample application for
4
+ [*Ruby on Rails Tutorial: Learn Web Development with Rails*](http://railstutorial.org/)
5
+ by [Michael Hartl](http://michaelhartl.com/). You can use this reference implementation to help track down errors if you end up having trouble with code in the tutorial. In particular, as a first debugging check I suggest getting the test suite to pass on your local machine:
6
+
7
+ cd /tmp
8
+ git clone https://github.com/railstutorial/sample_app_rails_4.git
9
+ cd sample_app_rails_4
10
+ cp config/database.yml.example config/database.yml
11
+ bundle install --without production
12
+ bundle exec rake db:migrate
13
+ bundle exec rake db:test:prepare
14
+ bundle exec rspec spec/
15
+
16
+ If the tests don't pass, it means there may be something wrong with your system. If they do pass, then you can debug your code by comparing it with the reference implementation.
17
+
18
+ ## Get Started in seconds on Nitrous.IO
19
+
20
+ [Nitrous.IO](https://www.nitrous.io/?utm_source=github.com&utm_campaign=railstutorial-sample_app_rails_4&utm_medium=hackonnitrous) is a cloud-based platform that will let you start working on this project in a matter of seconds.
21
+
22
+ Click on the button below to get started:
23
+
24
+ [![Hack railstutorial/sample_app_rails_4 on
25
+ Nitrous.IO](https://d3o0mnbgv6k92a.cloudfront.net/assets/hack-l-v1-3cc067e71372f6045e1949af9d96095b.png)](https://www.nitrous.io/hack_button?source=embed&runtime=rails&repo=railstutorial%2Fsample_app_rails_4&file_to_open=README.nitrous.md)
@@ -0,0 +1,20 @@
1
+ ## Get started with railstutorial/sample_app_rails_4
2
+
3
+ Run the following commands in the console below:
4
+
5
+ 1. `cd ~/workspace/sample_app_rails_4`
6
+ 2. `cp config/database.yml.example config/database.yml`
7
+ 3. `bundle install`
8
+ 4. `bundle exec rake db:migrate`
9
+ 5. `bundle exec rails server`
10
+
11
+ By clicking on Preview > Port 3000, you can now preview your sample
12
+ Rails App.
13
+
14
+ To check out more code, you can run tests, edit code and continue to
15
+ iterate on this application. To run the test suite, run the following
16
+ commands in the console:
17
+
18
+ 1. `cd ~/workspace/sample_app_rails_4`
19
+ 2. `bundle exec rake db:test:prepare`
20
+ 3. `bundle exec rspec spec`
@@ -0,0 +1,6 @@
1
+ # Add your own tasks in files placed in lib/tasks ending in .rake,
2
+ # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
3
+
4
+ require File.expand_path('../config/application', __FILE__)
5
+
6
+ SampleApp::Application.load_tasks
@@ -0,0 +1,17 @@
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 vendor/assets/javascripts of plugins, if any, 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
+ // WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD
11
+ // GO AFTER THE REQUIRES BELOW.
12
+ //
13
+ //= require jquery
14
+ //= require jquery_ujs
15
+ //= require turbolinks
16
+ //= require bootstrap
17
+ //= require_tree .
@@ -0,0 +1,3 @@
1
+ # Place all the behaviors and hooks related to the matching controller here.
2
+ # All this logic will automatically be available in application.js.
3
+ # You can use CoffeeScript in this file: http://coffeescript.org/
@@ -0,0 +1,3 @@
1
+ # Place all the behaviors and hooks related to the matching controller here.
2
+ # All this logic will automatically be available in application.js.
3
+ # You can use CoffeeScript in this file: http://coffeescript.org/
@@ -0,0 +1,3 @@
1
+ # Place all the behaviors and hooks related to the matching controller here.
2
+ # All this logic will automatically be available in application.js.
3
+ # You can use CoffeeScript in this file: http://coffeescript.org/
@@ -0,0 +1,13 @@
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 vendor/assets/stylesheets of plugins, if any, 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 top of the
9
+ * compiled file, but it's generally better to create a new file per style scope.
10
+ *
11
+ *= require_self
12
+ *= require_tree .
13
+ */
@@ -0,0 +1,246 @@
1
+ @import "bootstrap";
2
+
3
+ /* mixins, variables, etc. */
4
+
5
+ $grayMediumLight: #eaeaea;
6
+
7
+ @mixin box_sizing {
8
+ -moz-box-sizing: border-box;
9
+ -webkit-box-sizing: border-box;
10
+ box-sizing: border-box;
11
+ }
12
+
13
+ /* universal */
14
+
15
+ html {
16
+ overflow-y: scroll;
17
+ }
18
+
19
+ body {
20
+ padding-top: 60px;
21
+ }
22
+
23
+ section {
24
+ overflow: auto;
25
+ }
26
+
27
+ textarea {
28
+ resize: vertical;
29
+ }
30
+
31
+ .center {
32
+ text-align: center;
33
+ h1 {
34
+ margin-bottom: 10px;
35
+ }
36
+ }
37
+
38
+ /* typography */
39
+
40
+ h1, h2, h3, h4, h5, h6 {
41
+ line-height: 1;
42
+ }
43
+
44
+ h1 {
45
+ font-size: 3em;
46
+ letter-spacing: -2px;
47
+ margin-bottom: 30px;
48
+ text-align: center;
49
+ }
50
+
51
+ h2 {
52
+ font-size: 1.2em;
53
+ letter-spacing: -1px;
54
+ margin-bottom: 30px;
55
+ text-align: center;
56
+ font-weight: normal;
57
+ color: $grayLight;
58
+ }
59
+
60
+ p {
61
+ font-size: 1.1em;
62
+ line-height: 1.7em;
63
+ }
64
+
65
+
66
+ /* header */
67
+
68
+ #logo {
69
+ float: left;
70
+ margin-right: 10px;
71
+ font-size: 1.7em;
72
+ color: white;
73
+ text-transform: uppercase;
74
+ letter-spacing: -1px;
75
+ padding-top: 9px;
76
+ font-weight: bold;
77
+ line-height: 1;
78
+ &:hover {
79
+ color: white;
80
+ text-decoration: none;
81
+ }
82
+ }
83
+
84
+ /* footer */
85
+
86
+ footer {
87
+ margin-top: 45px;
88
+ padding-top: 5px;
89
+ border-top: 1px solid $grayMediumLight;
90
+ color: $grayLight;
91
+ a {
92
+ color: $gray;
93
+ &:hover {
94
+ color: $grayDarker;
95
+ }
96
+ }
97
+ small {
98
+ float: left;
99
+ }
100
+ ul {
101
+ float: right;
102
+ list-style: none;
103
+ li {
104
+ float: left;
105
+ margin-left: 10px;
106
+ }
107
+ }
108
+ }
109
+
110
+ /* miscellaneous */
111
+
112
+ .debug_dump {
113
+ clear: both;
114
+ float: left;
115
+ width: 100%;
116
+ margin-top: 45px;
117
+ @include box_sizing;
118
+ }
119
+
120
+ /* sidebar */
121
+
122
+ aside {
123
+ section {
124
+ padding: 10px 0;
125
+ border-top: 1px solid $grayLighter;
126
+ &:first-child {
127
+ border: 0;
128
+ padding-top: 0;
129
+ }
130
+ span {
131
+ display: block;
132
+ margin-bottom: 3px;
133
+ line-height: 1;
134
+ }
135
+ h1 {
136
+ font-size: 1.4em;
137
+ text-align: left;
138
+ letter-spacing: -1px;
139
+ margin-bottom: 3px;
140
+ margin-top: 0px;
141
+ }
142
+ }
143
+ }
144
+
145
+ .gravatar {
146
+ float: left;
147
+ margin-right: 10px;
148
+ }
149
+
150
+ .stats {
151
+ overflow: auto;
152
+ a {
153
+ float: left;
154
+ padding: 0 10px;
155
+ border-left: 1px solid $grayLighter;
156
+ color: gray;
157
+ &:first-child {
158
+ padding-left: 0;
159
+ border: 0;
160
+ }
161
+ &:hover {
162
+ text-decoration: none;
163
+ color: $blue;
164
+ }
165
+ }
166
+ strong {
167
+ display: block;
168
+ }
169
+ }
170
+
171
+ .user_avatars {
172
+ overflow: auto;
173
+ margin-top: 10px;
174
+ .gravatar {
175
+ margin: 1px 1px;
176
+ }
177
+ }
178
+
179
+ /* forms */
180
+
181
+ input, textarea, select, .uneditable-input {
182
+ border: 1px solid #bbb;
183
+ width: 100%;
184
+ margin-bottom: 15px;
185
+ @include box_sizing;
186
+ }
187
+
188
+ input {
189
+ height: auto !important;
190
+ }
191
+
192
+ #error_explanation {
193
+ color: #f00;
194
+ ul {
195
+ list-style: none;
196
+ margin: 0 0 18px 0;
197
+ }
198
+ }
199
+
200
+ .field_with_errors {
201
+ @extend .control-group;
202
+ @extend .error;
203
+ }
204
+
205
+ /* Users index */
206
+
207
+ .users {
208
+ list-style: none;
209
+ margin: 0;
210
+ li {
211
+ overflow: auto;
212
+ padding: 10px 0;
213
+ border-top: 1px solid $grayLighter;
214
+ &:last-child {
215
+ border-bottom: 1px solid $grayLighter;
216
+ }
217
+ }
218
+ }
219
+
220
+ /* microposts */
221
+
222
+ .microposts {
223
+ list-style: none;
224
+ margin: 10px 0 0 0;
225
+
226
+ li {
227
+ padding: 10px 0;
228
+ border-top: 1px solid #e8e8e8;
229
+ }
230
+ }
231
+ .content {
232
+ display: block;
233
+ }
234
+ .timestamp {
235
+ color: $grayLight;
236
+ }
237
+ .gravatar {
238
+ float: left;
239
+ margin-right: 10px;
240
+ }
241
+ aside {
242
+ textarea {
243
+ height: 100px;
244
+ margin-bottom: 5px;
245
+ }
246
+ }
@@ -0,0 +1,3 @@
1
+ // Place all the styles related to the Sessions controller here.
2
+ // They will automatically be included in application.css.
3
+ // You can use Sass (SCSS) here: http://sass-lang.com/
@@ -0,0 +1,3 @@
1
+ // Place all the styles related to the StaticPages controller here.
2
+ // They will automatically be included in application.css.
3
+ // You can use Sass (SCSS) here: http://sass-lang.com/
@@ -0,0 +1,3 @@
1
+ // Place all the styles related to the Users controller here.
2
+ // They will automatically be included in application.css.
3
+ // You can use Sass (SCSS) here: http://sass-lang.com/