Skip to content

Commit 176c4df

Browse files
committed
intial
0 parents  commit 176c4df

File tree

120 files changed

+2235
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

120 files changed

+2235
-0
lines changed

.gitignore

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# See https://help.github.com/articles/ignoring-files for more about ignoring files.
2+
#
3+
# If you find yourself ignoring temporary files generated by your text editor
4+
# or operating system, you probably want to add a global ignore instead:
5+
# git config --global core.excludesfile '~/.gitignore_global'
6+
7+
# Ignore bundler config.
8+
/.bundle
9+
10+
# Ignore the default SQLite database.
11+
/db/*.sqlite3
12+
/db/*.sqlite3-journal
13+
14+
# Ignore all logfiles and tempfiles.
15+
/log/*
16+
/tmp/*
17+
!/log/.keep
18+
!/tmp/.keep
19+
20+
# Ignore Byebug command history file.
21+
.byebug_history

Gemfile

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
source 'https://ruby.taobao.org'
2+
3+
git_source(:github) do |repo_name|
4+
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/")
5+
"https://github.com/#{repo_name}.git"
6+
end
7+
8+
9+
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
10+
gem 'rails', '~> 5.0.2'
11+
# Use sqlite3 as the database for Active Record
12+
gem 'sqlite3'
13+
# Use Puma as the app server
14+
gem 'puma', '~> 3.0'
15+
# Use SCSS for stylesheets
16+
gem 'sass-rails', '~> 5.0'
17+
# Use Uglifier as compressor for JavaScript assets
18+
gem 'uglifier', '>= 1.3.0'
19+
# Use CoffeeScript for .coffee assets and views
20+
gem 'coffee-rails', '~> 4.2'
21+
# See https://github.com/rails/execjs#readme for more supported runtimes
22+
# gem 'therubyracer', platforms: :ruby
23+
24+
# Use jquery as the JavaScript library
25+
gem 'jquery-rails'
26+
# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
27+
gem 'turbolinks', '~> 5'
28+
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
29+
gem 'jbuilder', '~> 2.5'
30+
# Use Redis adapter to run Action Cable in production
31+
# gem 'redis', '~> 3.0'
32+
# Use ActiveModel has_secure_password
33+
gem 'bcrypt', '~> 3.1.7'
34+
35+
# Use Capistrano for deployment
36+
# gem 'capistrano-rails', group: :development
37+
38+
group :development, :test do
39+
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
40+
gem 'byebug', platform: :mri
41+
end
42+
43+
group :development do
44+
# Access an IRB console on exception pages or by using <%= console %> anywhere in the code.
45+
gem 'web-console', '>= 3.3.0'
46+
gem 'listen', '~> 3.0.5'
47+
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
48+
gem 'spring'
49+
gem 'spring-watcher-listen', '~> 2.0.0'
50+
end
51+
52+
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
53+
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
54+
55+
56+
gem 'devise'
57+
gem 'rails_admin', '~> 1.1.1'

Gemfile.lock

Lines changed: 216 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,216 @@
1+
GEM
2+
remote: https://ruby.taobao.org/
3+
specs:
4+
actioncable (5.0.2)
5+
actionpack (= 5.0.2)
6+
nio4r (>= 1.2, < 3.0)
7+
websocket-driver (~> 0.6.1)
8+
actionmailer (5.0.2)
9+
actionpack (= 5.0.2)
10+
actionview (= 5.0.2)
11+
activejob (= 5.0.2)
12+
mail (~> 2.5, >= 2.5.4)
13+
rails-dom-testing (~> 2.0)
14+
actionpack (5.0.2)
15+
actionview (= 5.0.2)
16+
activesupport (= 5.0.2)
17+
rack (~> 2.0)
18+
rack-test (~> 0.6.3)
19+
rails-dom-testing (~> 2.0)
20+
rails-html-sanitizer (~> 1.0, >= 1.0.2)
21+
actionview (5.0.2)
22+
activesupport (= 5.0.2)
23+
builder (~> 3.1)
24+
erubis (~> 2.7.0)
25+
rails-dom-testing (~> 2.0)
26+
rails-html-sanitizer (~> 1.0, >= 1.0.3)
27+
activejob (5.0.2)
28+
activesupport (= 5.0.2)
29+
globalid (>= 0.3.6)
30+
activemodel (5.0.2)
31+
activesupport (= 5.0.2)
32+
activerecord (5.0.2)
33+
activemodel (= 5.0.2)
34+
activesupport (= 5.0.2)
35+
arel (~> 7.0)
36+
activesupport (5.0.2)
37+
concurrent-ruby (~> 1.0, >= 1.0.2)
38+
i18n (~> 0.7)
39+
minitest (~> 5.1)
40+
tzinfo (~> 1.1)
41+
arel (7.1.4)
42+
bcrypt (3.1.11)
43+
builder (3.2.3)
44+
byebug (9.0.6)
45+
coffee-rails (4.2.1)
46+
coffee-script (>= 2.2.0)
47+
railties (>= 4.0.0, < 5.2.x)
48+
coffee-script (2.4.1)
49+
coffee-script-source
50+
execjs
51+
coffee-script-source (1.12.2)
52+
concurrent-ruby (1.0.5)
53+
debug_inspector (0.0.2)
54+
devise (4.2.1)
55+
bcrypt (~> 3.0)
56+
orm_adapter (~> 0.1)
57+
railties (>= 4.1.0, < 5.1)
58+
responders
59+
warden (~> 1.2.3)
60+
erubis (2.7.0)
61+
execjs (2.7.0)
62+
ffi (1.9.18)
63+
font-awesome-rails (4.7.0.1)
64+
railties (>= 3.2, < 5.1)
65+
globalid (0.3.7)
66+
activesupport (>= 4.1.0)
67+
haml (4.0.7)
68+
tilt
69+
i18n (0.8.1)
70+
jbuilder (2.6.3)
71+
activesupport (>= 3.0.0, < 5.2)
72+
multi_json (~> 1.2)
73+
jquery-rails (4.3.1)
74+
rails-dom-testing (>= 1, < 3)
75+
railties (>= 4.2.0)
76+
thor (>= 0.14, < 2.0)
77+
jquery-ui-rails (5.0.5)
78+
railties (>= 3.2.16)
79+
kaminari (0.17.0)
80+
actionpack (>= 3.0.0)
81+
activesupport (>= 3.0.0)
82+
listen (3.0.8)
83+
rb-fsevent (~> 0.9, >= 0.9.4)
84+
rb-inotify (~> 0.9, >= 0.9.7)
85+
loofah (2.0.3)
86+
nokogiri (>= 1.5.9)
87+
mail (2.6.4)
88+
mime-types (>= 1.16, < 4)
89+
method_source (0.8.2)
90+
mime-types (3.1)
91+
mime-types-data (~> 3.2015)
92+
mime-types-data (3.2016.0521)
93+
mini_portile2 (2.1.0)
94+
minitest (5.10.1)
95+
multi_json (1.12.1)
96+
nested_form (0.3.2)
97+
nio4r (2.0.0)
98+
nokogiri (1.7.1)
99+
mini_portile2 (~> 2.1.0)
100+
orm_adapter (0.5.0)
101+
puma (3.8.2)
102+
rack (2.0.1)
103+
rack-pjax (1.0.0)
104+
nokogiri (~> 1.5)
105+
rack (>= 1.1)
106+
rack-test (0.6.3)
107+
rack (>= 1.0)
108+
rails (5.0.2)
109+
actioncable (= 5.0.2)
110+
actionmailer (= 5.0.2)
111+
actionpack (= 5.0.2)
112+
actionview (= 5.0.2)
113+
activejob (= 5.0.2)
114+
activemodel (= 5.0.2)
115+
activerecord (= 5.0.2)
116+
activesupport (= 5.0.2)
117+
bundler (>= 1.3.0, < 2.0)
118+
railties (= 5.0.2)
119+
sprockets-rails (>= 2.0.0)
120+
rails-dom-testing (2.0.2)
121+
activesupport (>= 4.2.0, < 6.0)
122+
nokogiri (~> 1.6)
123+
rails-html-sanitizer (1.0.3)
124+
loofah (~> 2.0)
125+
rails_admin (1.1.1)
126+
builder (~> 3.1)
127+
coffee-rails (~> 4.0)
128+
font-awesome-rails (>= 3.0, < 5)
129+
haml (~> 4.0)
130+
jquery-rails (>= 3.0, < 5)
131+
jquery-ui-rails (~> 5.0)
132+
kaminari (~> 0.14)
133+
nested_form (~> 0.3)
134+
rack-pjax (>= 0.7)
135+
rails (>= 4.0, < 6)
136+
remotipart (~> 1.3)
137+
sass-rails (>= 4.0, < 6)
138+
railties (5.0.2)
139+
actionpack (= 5.0.2)
140+
activesupport (= 5.0.2)
141+
method_source
142+
rake (>= 0.8.7)
143+
thor (>= 0.18.1, < 2.0)
144+
rake (12.0.0)
145+
rb-fsevent (0.9.8)
146+
rb-inotify (0.9.8)
147+
ffi (>= 0.5.0)
148+
remotipart (1.3.1)
149+
responders (2.3.0)
150+
railties (>= 4.2.0, < 5.1)
151+
sass (3.4.23)
152+
sass-rails (5.0.6)
153+
railties (>= 4.0.0, < 6)
154+
sass (~> 3.1)
155+
sprockets (>= 2.8, < 4.0)
156+
sprockets-rails (>= 2.0, < 4.0)
157+
tilt (>= 1.1, < 3)
158+
spring (2.0.1)
159+
activesupport (>= 4.2)
160+
spring-watcher-listen (2.0.1)
161+
listen (>= 2.7, < 4.0)
162+
spring (>= 1.2, < 3.0)
163+
sprockets (3.7.1)
164+
concurrent-ruby (~> 1.0)
165+
rack (> 1, < 3)
166+
sprockets-rails (3.2.0)
167+
actionpack (>= 4.0)
168+
activesupport (>= 4.0)
169+
sprockets (>= 3.0.0)
170+
sqlite3 (1.3.13)
171+
thor (0.19.4)
172+
thread_safe (0.3.6)
173+
tilt (2.0.7)
174+
turbolinks (5.0.1)
175+
turbolinks-source (~> 5)
176+
turbolinks-source (5.0.0)
177+
tzinfo (1.2.3)
178+
thread_safe (~> 0.1)
179+
uglifier (3.1.11)
180+
execjs (>= 0.3.0, < 3)
181+
warden (1.2.7)
182+
rack (>= 1.0)
183+
web-console (3.4.0)
184+
actionview (>= 5.0)
185+
activemodel (>= 5.0)
186+
debug_inspector
187+
railties (>= 5.0)
188+
websocket-driver (0.6.5)
189+
websocket-extensions (>= 0.1.0)
190+
websocket-extensions (0.1.2)
191+
192+
PLATFORMS
193+
ruby
194+
195+
DEPENDENCIES
196+
bcrypt (~> 3.1.7)
197+
byebug
198+
coffee-rails (~> 4.2)
199+
devise
200+
jbuilder (~> 2.5)
201+
jquery-rails
202+
listen (~> 3.0.5)
203+
puma (~> 3.0)
204+
rails (~> 5.0.2)
205+
rails_admin (~> 1.1.1)
206+
sass-rails (~> 5.0)
207+
spring
208+
spring-watcher-listen (~> 2.0.0)
209+
sqlite3
210+
turbolinks (~> 5)
211+
tzinfo-data
212+
uglifier (>= 1.3.0)
213+
web-console (>= 3.3.0)
214+
215+
BUNDLED WITH
216+
1.13.7

README.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
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+
* ...

Rakefile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -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_relative 'config/application'
5+
6+
Rails.application.load_tasks

app/assets/config/manifest.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
//= link_tree ../images
2+
//= link_directory ../javascripts .js
3+
//= link_directory ../stylesheets .css

app/assets/images/.keep

Whitespace-only changes.

app/assets/javascripts/application.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
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. JavaScript code in this file should be added after the last require_* statement.
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 .

app/assets/javascripts/cable.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Action Cable provides the framework to deal with WebSockets in Rails.
2+
// You can generate new channels where WebSocket features live using the rails generate channel command.
3+
//
4+
//= require action_cable
5+
//= require_self
6+
//= require_tree ./channels
7+
8+
(function() {
9+
this.App || (this.App = {});
10+
11+
App.cable = ActionCable.createConsumer();
12+
13+
}).call(this);

app/assets/javascripts/channels/.keep

Whitespace-only changes.

app/assets/javascripts/home.coffee

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -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/

app/assets/javascripts/posts.coffee

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -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/
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
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 other CSS/SCSS
10+
* files in this directory. Styles in this file should be added after the last require_* statement.
11+
* It is generally better to create a new file per style scope.
12+
*
13+
*= require_tree .
14+
*= require_self
15+
*/

app/assets/stylesheets/home.scss

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// Place all the styles related to the Home controller here.
2+
// They will automatically be included in application.css.
3+
// You can use Sass (SCSS) here: http://sass-lang.com/

app/assets/stylesheets/posts.scss

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// Place all the styles related to the posts controller here.
2+
// They will automatically be included in application.css.
3+
// You can use Sass (SCSS) here: http://sass-lang.com/

0 commit comments

Comments
 (0)