smalruby-editor 0.0.1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of smalruby-editor might be problematic. Click here for more details.

Files changed (77) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +24 -0
  3. data/.rspec +3 -0
  4. data/.ruby-version +1 -0
  5. data/.simplecov +7 -0
  6. data/.travis.yml +23 -0
  7. data/Gemfile +77 -0
  8. data/Gemfile.lock +258 -0
  9. data/LICENSE +22 -0
  10. data/Procfile +1 -0
  11. data/README.rdoc +45 -0
  12. data/Rakefile +6 -0
  13. data/app/assets/images/.keep +0 -0
  14. data/app/assets/images/favicon.ico +0 -0
  15. data/app/assets/javascripts/application.js +21 -0
  16. data/app/assets/javascripts/editor.js.coffee +52 -0
  17. data/app/assets/stylesheets/application.css +20 -0
  18. data/app/assets/stylesheets/editor.css.scss +13 -0
  19. data/app/controllers/application_controller.rb +5 -0
  20. data/app/controllers/concerns/.keep +0 -0
  21. data/app/controllers/editor_controller.rb +22 -0
  22. data/app/helpers/application_helper.rb +2 -0
  23. data/app/helpers/editor_helper.rb +2 -0
  24. data/app/mailers/.keep +0 -0
  25. data/app/models/.keep +0 -0
  26. data/app/models/concerns/.keep +0 -0
  27. data/app/views/editor/index.html.erb +16 -0
  28. data/app/views/layouts/application.html.erb +15 -0
  29. data/bin/bundle +3 -0
  30. data/bin/rails +4 -0
  31. data/bin/rake +4 -0
  32. data/bin/smalruby-editor +86 -0
  33. data/config.ru +4 -0
  34. data/config/application.rb +28 -0
  35. data/config/boot.rb +4 -0
  36. data/config/database.yml.mysql2 +39 -0
  37. data/config/database.yml.sqlite3 +25 -0
  38. data/config/database.yml.travis +5 -0
  39. data/config/environment.rb +5 -0
  40. data/config/environments/development.rb +29 -0
  41. data/config/environments/production.rb +80 -0
  42. data/config/environments/standalone.rb +15 -0
  43. data/config/environments/test.rb +36 -0
  44. data/config/initializers/backtrace_silencers.rb +7 -0
  45. data/config/initializers/filter_parameter_logging.rb +4 -0
  46. data/config/initializers/inflections.rb +16 -0
  47. data/config/initializers/mime_types.rb +5 -0
  48. data/config/initializers/secret_token.rb +12 -0
  49. data/config/initializers/session_store.rb +3 -0
  50. data/config/initializers/wrap_parameters.rb +14 -0
  51. data/config/locales/en.yml +23 -0
  52. data/config/routes.rb +63 -0
  53. data/config/unicorn.rb +22 -0
  54. data/db/schema.rb +16 -0
  55. data/db/seeds.rb +7 -0
  56. data/lib/assets/.keep +0 -0
  57. data/lib/smalruby_editor.rb +4 -0
  58. data/lib/smalruby_editor/version.rb +3 -0
  59. data/lib/tasks/.keep +0 -0
  60. data/lib/tasks/gem.rake +5 -0
  61. data/lib/tasks/rspec.rake +16 -0
  62. data/log/.keep +0 -0
  63. data/public/404.html +58 -0
  64. data/public/422.html +58 -0
  65. data/public/500.html +57 -0
  66. data/public/favicon.ico +0 -0
  67. data/public/robots.txt +5 -0
  68. data/smalruby-editor.gemspec +50 -0
  69. data/spec/acceptance/editor.feature +58 -0
  70. data/spec/controllers/editor_controller_spec.rb +52 -0
  71. data/spec/fixtures/files/01.rb +57 -0
  72. data/spec/helpers/editor_helper_spec.rb +14 -0
  73. data/spec/spec_helper.rb +70 -0
  74. data/spec/steps/editor_steps.rb +106 -0
  75. data/vendor/assets/javascripts/.keep +0 -0
  76. data/vendor/assets/stylesheets/.keep +0 -0
  77. metadata +367 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 04a3b9b6a1c33d83c3d8cf22ea3d005197cafddd
4
+ data.tar.gz: f106c0645cf21b7421fc22f9a3d194a7790c9b1d
5
+ SHA512:
6
+ metadata.gz: 274105e6a270aff53e6102e4b97d83e971922da06748b3a3526c86bc8abeba9f283cfd135331d8058d704d99c3bc8d873d38ffd0da91ff361b146eb48004b8b1
7
+ data.tar.gz: 39fb4f0982470bbe4a6f6012a09df6860a7474d0bb8ddf71ec2828137c0084a94f96404023e9849ac7fdba7b194991c86641278c0142da7601d4787f83be8c11
data/.gitignore ADDED
@@ -0,0 +1,24 @@
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/*.log
16
+ /tmp
17
+
18
+ /config/database.yml
19
+
20
+ /public/assets
21
+
22
+ /.env
23
+ /coverage
24
+ /pkg
data/.rspec ADDED
@@ -0,0 +1,3 @@
1
+ --color
2
+ --format documentation
3
+ -r turnip/rspec
data/.ruby-version ADDED
@@ -0,0 +1 @@
1
+ 2.0.0-p353
data/.simplecov ADDED
@@ -0,0 +1,7 @@
1
+ if ENV['COVERALLS']
2
+ require 'coveralls'
3
+
4
+ SimpleCov.formatter = Coveralls::SimpleCov::Formatter
5
+ end
6
+
7
+ SimpleCov.start('rails')
data/.travis.yml ADDED
@@ -0,0 +1,23 @@
1
+ language: ruby
2
+
3
+ rvm:
4
+ - 2.0.0
5
+
6
+ before_script:
7
+ - cp config/database.yml.travis config/database.yml
8
+ - mysql -e 'create database myapp_test;'
9
+
10
+ script:
11
+ - export SECRET_KEY_BASE='xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'
12
+ - export COVERALLS='1'
13
+ - RAILS_ENV=test bundle exec rake db:migrate --trace
14
+ - bundle exec rake db:test:prepare
15
+ - bundle exec rake
16
+
17
+ deploy:
18
+ provider: heroku
19
+ api_key:
20
+ secure: HqZ7FylThjaB3XguCZJbccu7dB8CvWIWFlZpWLLfJwfUkjvoEC1F6VPFakFbwjLXLsvaKlYLakzL+bhaLnxu+HyeNmCrvpIRR2j8EuHmSkxdWrlxAZRV2ojHuDpZuVNaEzd7YtcBCoPiTvqnxWzhAfzZWbPrZfCdA1f+5t5/So0=
21
+ app: smalruby
22
+ on:
23
+ repo: smalruby/smalruby-editor
data/Gemfile ADDED
@@ -0,0 +1,77 @@
1
+ source 'https://rubygems.org'
2
+
3
+ ruby '2.0.0'
4
+
5
+ # Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
6
+ gem 'rails', '4.0.1'
7
+
8
+ # Use SCSS for stylesheets
9
+ gem 'sass-rails', '~> 4.0.0'
10
+
11
+ # Use Uglifier as compressor for JavaScript assets
12
+ gem 'uglifier', '>= 1.3.0'
13
+
14
+ # Use CoffeeScript for .js.coffee assets and views
15
+ gem 'coffee-rails', '~> 4.0.0'
16
+
17
+ # See https://github.com/sstephenson/execjs#readme for more supported runtimes
18
+ # gem 'therubyracer', platforms: :ruby
19
+
20
+ # Use jquery as the JavaScript library
21
+ gem 'jquery-rails'
22
+
23
+ # Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
24
+ gem 'turbolinks'
25
+
26
+ # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
27
+ gem 'jbuilder', '~> 1.2'
28
+
29
+ gem 'ace-rails-ap', github: 'dedico/ace-rails-ap'
30
+
31
+ gem 'flatstrap-sass'
32
+
33
+ gem 'font-awesome-rails'
34
+
35
+ gem 'jquery-fileupload-rails', github: 'demiazz/jquery-fileupload-rails'
36
+
37
+ group :doc do
38
+ # bundle exec rake doc:rails generates the API under doc/api.
39
+ gem 'sdoc', require: false
40
+ end
41
+
42
+ # Use ActiveModel has_secure_password
43
+ # gem 'bcrypt-ruby', '~> 3.1.2'
44
+
45
+ # Use unicorn as the app server
46
+ # gem 'unicorn'
47
+
48
+ # Use Capistrano for deployment
49
+ # gem 'capistrano', group: :development
50
+
51
+ # Use debugger
52
+ # gem 'debugger', group: [:development, :test]
53
+
54
+ group :production do
55
+ # Use mysql as the database for Active Record
56
+ gem 'mysql2'
57
+
58
+ gem 'rails_12factor'
59
+ gem 'unicorn', platforms: :ruby
60
+ end
61
+
62
+ group :development, :test do
63
+ gem 'sqlite3'
64
+ gem 'commands'
65
+ gem 'rubocop'
66
+ gem 'rspec-rails'
67
+ end
68
+
69
+ group :test do
70
+ gem 'shoulda-matchers'
71
+ gem 'capybara'
72
+ gem 'selenium-webdriver'
73
+ gem 'poltergeist'
74
+ gem 'turnip'
75
+ gem 'coveralls', require: false
76
+ gem 'json_spec'
77
+ end
data/Gemfile.lock ADDED
@@ -0,0 +1,258 @@
1
+ GIT
2
+ remote: git://github.com/dedico/ace-rails-ap.git
3
+ revision: 7c42a42161d126b5271bfde813129219e997a879
4
+ specs:
5
+ ace-rails-ap (2.0.0)
6
+
7
+ GIT
8
+ remote: git://github.com/demiazz/jquery-fileupload-rails.git
9
+ revision: 9524ff75e42551ea84cf4aec6210640dddfc000d
10
+ specs:
11
+ jquery-fileupload-rails (0.4.1)
12
+ actionpack (>= 3.1)
13
+ railties (>= 3.1)
14
+
15
+ GEM
16
+ remote: https://rubygems.org/
17
+ specs:
18
+ actionmailer (4.0.1)
19
+ actionpack (= 4.0.1)
20
+ mail (~> 2.5.4)
21
+ actionpack (4.0.1)
22
+ activesupport (= 4.0.1)
23
+ builder (~> 3.1.0)
24
+ erubis (~> 2.7.0)
25
+ rack (~> 1.5.2)
26
+ rack-test (~> 0.6.2)
27
+ activemodel (4.0.1)
28
+ activesupport (= 4.0.1)
29
+ builder (~> 3.1.0)
30
+ activerecord (4.0.1)
31
+ activemodel (= 4.0.1)
32
+ activerecord-deprecated_finders (~> 1.0.2)
33
+ activesupport (= 4.0.1)
34
+ arel (~> 4.0.0)
35
+ activerecord-deprecated_finders (1.0.3)
36
+ activesupport (4.0.1)
37
+ i18n (~> 0.6, >= 0.6.4)
38
+ minitest (~> 4.2)
39
+ multi_json (~> 1.3)
40
+ thread_safe (~> 0.1)
41
+ tzinfo (~> 0.3.37)
42
+ arel (4.0.1)
43
+ ast (1.1.0)
44
+ atomic (1.1.14)
45
+ builder (3.1.4)
46
+ capybara (2.1.0)
47
+ mime-types (>= 1.16)
48
+ nokogiri (>= 1.3.3)
49
+ rack (>= 1.0.0)
50
+ rack-test (>= 0.5.4)
51
+ xpath (~> 2.0)
52
+ childprocess (0.3.9)
53
+ ffi (~> 1.0, >= 1.0.11)
54
+ cliver (0.2.2)
55
+ coffee-rails (4.0.1)
56
+ coffee-script (>= 2.2.0)
57
+ railties (>= 4.0.0, < 5.0)
58
+ coffee-script (2.2.0)
59
+ coffee-script-source
60
+ execjs
61
+ coffee-script-source (1.6.3)
62
+ commands (0.2.1)
63
+ rails (>= 3.2.0)
64
+ coveralls (0.7.0)
65
+ multi_json (~> 1.3)
66
+ rest-client
67
+ simplecov (>= 0.7)
68
+ term-ansicolor
69
+ thor
70
+ diff-lcs (1.2.5)
71
+ docile (1.1.0)
72
+ erubis (2.7.0)
73
+ execjs (2.0.2)
74
+ ffi (1.9.3)
75
+ ffi (1.9.3-x86-mingw32)
76
+ flatstrap-sass (2.3.1.0)
77
+ font-awesome-rails (~> 3.0.2.0)
78
+ sass (~> 3.2)
79
+ font-awesome-rails (3.0.2.0)
80
+ railties (>= 3.1)
81
+ gherkin (2.12.2)
82
+ multi_json (~> 1.3)
83
+ gherkin (2.12.2-x86-mingw32)
84
+ multi_json (~> 1.3)
85
+ hike (1.2.3)
86
+ i18n (0.6.5)
87
+ jbuilder (1.5.2)
88
+ activesupport (>= 3.0.0)
89
+ multi_json (>= 1.2.0)
90
+ jquery-rails (3.0.4)
91
+ railties (>= 3.0, < 5.0)
92
+ thor (>= 0.14, < 2.0)
93
+ json (1.8.1)
94
+ json_spec (1.1.1)
95
+ multi_json (~> 1.0)
96
+ rspec (~> 2.0)
97
+ kgio (2.8.1)
98
+ mail (2.5.4)
99
+ mime-types (~> 1.16)
100
+ treetop (~> 1.4.8)
101
+ mime-types (1.25.1)
102
+ mini_portile (0.5.2)
103
+ minitest (4.7.5)
104
+ multi_json (1.8.2)
105
+ mysql2 (0.3.14)
106
+ nokogiri (1.6.0)
107
+ mini_portile (~> 0.5.0)
108
+ nokogiri (1.6.0-x86-mingw32)
109
+ mini_portile (~> 0.5.0)
110
+ parser (2.0.0)
111
+ ast (~> 1.1)
112
+ slop (~> 3.4, >= 3.4.5)
113
+ poltergeist (1.4.1)
114
+ capybara (~> 2.1.0)
115
+ cliver (~> 0.2.1)
116
+ multi_json (~> 1.0)
117
+ websocket-driver (>= 0.2.0)
118
+ polyglot (0.3.3)
119
+ powerpack (0.0.9)
120
+ rack (1.5.2)
121
+ rack-test (0.6.2)
122
+ rack (>= 1.0)
123
+ rails (4.0.1)
124
+ actionmailer (= 4.0.1)
125
+ actionpack (= 4.0.1)
126
+ activerecord (= 4.0.1)
127
+ activesupport (= 4.0.1)
128
+ bundler (>= 1.3.0, < 2.0)
129
+ railties (= 4.0.1)
130
+ sprockets-rails (~> 2.0.0)
131
+ rails_12factor (0.0.2)
132
+ rails_serve_static_assets
133
+ rails_stdout_logging
134
+ rails_serve_static_assets (0.0.1)
135
+ rails_stdout_logging (0.0.3)
136
+ railties (4.0.1)
137
+ actionpack (= 4.0.1)
138
+ activesupport (= 4.0.1)
139
+ rake (>= 0.8.7)
140
+ thor (>= 0.18.1, < 2.0)
141
+ rainbow (1.1.4)
142
+ raindrops (0.12.0)
143
+ rake (10.1.0)
144
+ rdoc (3.12.2)
145
+ json (~> 1.4)
146
+ rest-client (1.6.7)
147
+ mime-types (>= 1.16)
148
+ rspec (2.14.1)
149
+ rspec-core (~> 2.14.0)
150
+ rspec-expectations (~> 2.14.0)
151
+ rspec-mocks (~> 2.14.0)
152
+ rspec-core (2.14.7)
153
+ rspec-expectations (2.14.4)
154
+ diff-lcs (>= 1.1.3, < 2.0)
155
+ rspec-mocks (2.14.4)
156
+ rspec-rails (2.14.0)
157
+ actionpack (>= 3.0)
158
+ activesupport (>= 3.0)
159
+ railties (>= 3.0)
160
+ rspec-core (~> 2.14.0)
161
+ rspec-expectations (~> 2.14.0)
162
+ rspec-mocks (~> 2.14.0)
163
+ rubocop (0.15.0)
164
+ parser (~> 2.0)
165
+ powerpack (~> 0.0.6)
166
+ rainbow (>= 1.1.4)
167
+ rubyzip (1.0.0)
168
+ sass (3.2.12)
169
+ sass-rails (4.0.1)
170
+ railties (>= 4.0.0, < 5.0)
171
+ sass (>= 3.1.10)
172
+ sprockets-rails (~> 2.0.0)
173
+ sdoc (0.3.20)
174
+ json (>= 1.1.3)
175
+ rdoc (~> 3.10)
176
+ selenium-webdriver (2.37.0)
177
+ childprocess (>= 0.2.5)
178
+ multi_json (~> 1.0)
179
+ rubyzip (~> 1.0.0)
180
+ websocket (~> 1.0.4)
181
+ shoulda-matchers (2.4.0)
182
+ activesupport (>= 3.0.0)
183
+ simplecov (0.8.2)
184
+ docile (~> 1.1.0)
185
+ multi_json
186
+ simplecov-html (~> 0.8.0)
187
+ simplecov-html (0.8.0)
188
+ slop (3.4.7)
189
+ sprockets (2.10.1)
190
+ hike (~> 1.2)
191
+ multi_json (~> 1.0)
192
+ rack (~> 1.0)
193
+ tilt (~> 1.1, != 1.3.0)
194
+ sprockets-rails (2.0.1)
195
+ actionpack (>= 3.0)
196
+ activesupport (>= 3.0)
197
+ sprockets (~> 2.8)
198
+ sqlite3 (1.3.8)
199
+ sqlite3 (1.3.8-x86-mingw32)
200
+ term-ansicolor (1.2.2)
201
+ tins (~> 0.8)
202
+ thor (0.18.1)
203
+ thread_safe (0.1.3)
204
+ atomic
205
+ tilt (1.4.1)
206
+ tins (0.13.1)
207
+ treetop (1.4.15)
208
+ polyglot
209
+ polyglot (>= 0.3.1)
210
+ turbolinks (1.3.1)
211
+ coffee-rails
212
+ turnip (1.1.0)
213
+ gherkin (>= 2.5)
214
+ rspec (~> 2.0)
215
+ tzinfo (0.3.38)
216
+ uglifier (2.3.1)
217
+ execjs (>= 0.3.0)
218
+ json (>= 1.8.0)
219
+ unicorn (4.7.0)
220
+ kgio (~> 2.6)
221
+ rack
222
+ raindrops (~> 0.7)
223
+ websocket (1.0.7)
224
+ websocket-driver (0.3.0)
225
+ xpath (2.0.0)
226
+ nokogiri (~> 1.3)
227
+
228
+ PLATFORMS
229
+ ruby
230
+ x86-mingw32
231
+
232
+ DEPENDENCIES
233
+ ace-rails-ap!
234
+ capybara
235
+ coffee-rails (~> 4.0.0)
236
+ commands
237
+ coveralls
238
+ flatstrap-sass
239
+ font-awesome-rails
240
+ jbuilder (~> 1.2)
241
+ jquery-fileupload-rails!
242
+ jquery-rails
243
+ json_spec
244
+ mysql2
245
+ poltergeist
246
+ rails (= 4.0.1)
247
+ rails_12factor
248
+ rspec-rails
249
+ rubocop
250
+ sass-rails (~> 4.0.0)
251
+ sdoc
252
+ selenium-webdriver
253
+ shoulda-matchers
254
+ sqlite3
255
+ turbolinks
256
+ turnip
257
+ uglifier (>= 1.3.0)
258
+ unicorn
data/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2013 Kouji Takao
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/Procfile ADDED
@@ -0,0 +1 @@
1
+ web: bundle exec unicorn -p $PORT -c ./config/unicorn.rb
data/README.rdoc ADDED
@@ -0,0 +1,45 @@
1
+ == smalruby-editor
2
+
3
+ {<img src="https://travis-ci.org/smalruby/smalruby-editor.png?branch=master" alt="Build Status" />}[https://travis-ci.org/smalruby/smalruby-editor]
4
+ {<img src="https://coveralls.io/repos/smalruby/smalruby-editor/badge.png?branch=master" alt="Coverage Status" />}[https://coveralls.io/r/smalruby/smalruby-editor?branch=master]
5
+ {<img src="https://codeclimate.com/github/smalruby/smalruby-editor.png" />}[https://codeclimate.com/github/smalruby/smalruby-editor]
6
+ {<img src="https://gemnasium.com/takaokouji/smalruby-editor.png" alt="Dependency Status" />}[https://gemnasium.com/takaokouji/smalruby-editor]
7
+
8
+ The smalruby-editor is a visual programming editor that can create a Ruby script by combining individual blocks similar to Scratch. It can also enter the program as better than Scratch.
9
+
10
+ The smalruby-editor is a part of the Smalruby Project.
11
+
12
+ The Smalruby(smɔ́ːrúːbi) Project will provide a Ruby learning environment for middle school students from the upper grades of elementary school. The goal of this project is to achieve software and community sites such as the {Scratch}[http://scratch.mit.edu/] in Ruby. The Scratch has experience as educational programming environment can be used in elementary school. This project consists of the following elements.
13
+
14
+ == Installation (for Developer)
15
+
16
+ requirements:
17
+
18
+ * Windows or UNIX like OS (Mac OS X, Linux, etc...)
19
+ * Ruby 2.0.0-p247 or higher.
20
+ * MySQL
21
+ * Git
22
+
23
+ execute below commands.
24
+
25
+ git clone https://github.com/smalruby/smalruby-editor.git
26
+ cd smalruby-editor
27
+ bundle
28
+ rake db:create
29
+ rake db:migrate
30
+ rake
31
+ rails server
32
+
33
+ access <tt>localhost:3000</tt> with your web browser.
34
+
35
+ == Contributing
36
+
37
+ 1. Fork it
38
+ 2. Create your feature branch (<tt>git checkout -b my-new-feature</tt>)
39
+ 3. Commit your changes (<tt>git commit -am 'Add some feature'</tt>)
40
+ 4. Push to the branch (<tt>git push origin my-new-feature</tt>)
41
+ 5. Create new Pull Request
42
+
43
+ == License
44
+
45
+ MIT (see link:LICENSE)