actionframework 0.1.3.0 → 0.1.3.1

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: 60241b90fa1f54a14bb9867291ce9bd37d30671b
4
- data.tar.gz: 74630ec145734f516f6c45650846df9669ad3660
3
+ metadata.gz: 3879210a859f1a2728b8ca0f2642b4e529fb8ea0
4
+ data.tar.gz: d7fc08535d2158912c144b744ffec1b482dc5d04
5
5
  SHA512:
6
- metadata.gz: 784920955d45bb83d8a0cf571facb150df872399ab664c000f4be2ee50867bda8c76734cfde149c47f29916e9ffb742dea96bfa87a5dbb5120f49dbbb5c6fb02
7
- data.tar.gz: fdf6ba7989d475b8f0f00381c36f25d53a9c14aea5dfdde26295c1a5f7b2095bf8afe1b22ac528ad792fd67cef3115b2a57d1727b8fc2d4375c5da0e37b7318d
6
+ metadata.gz: bfce7e8519dec444747e0c701bc5cae9007ed1e0e8847ee38e8e5ac40d6d138ddea8aa82178566e1d6fed5408517fce8fc11194e4870cc25a77752511372826c
7
+ data.tar.gz: 793bdcc2e91e668350e262f05cee9f9986a16a1a2ca859dc771d4043269dc754309592d4cea931e32f158acd01f12cbf9bec716463fe4279d76d9fdc50684101
data/bin/action CHANGED
@@ -45,16 +45,18 @@ class ActionFrameworkCLI < Optitron::CLI
45
45
  FileUtils.touch("#{projectname}/Gemfile")
46
46
  File.write("#{projectname}/main.rb","# Example of basic configuration\nActionFramework = ActionFramework::Server.new\n\nnActionFramework.autoimport\nActionFramework.start")
47
47
  File.write("#{projectname}/controllers/default_controller.rb","class DefaultController < ActionFramework::Controller
48
- \n def index\n \"<h1>Welcome to ActionFramework</h1><i>Great Opensource Ruby Server</i><p>ActionFramework is loading routes from routes.json but you should write your own main.rb<br/>This is just to gettings started</p>\"\n end\nend");
48
+ \n def index\n erb \"index\" \n end\nend");
49
49
  File.write("#{projectname}/routes.json","{\n \"get\": [{\n \"/\": \"DefaultController#index\"\n}]\n}")
50
50
  File.write("#{projectname}/config/routes.rb","ActionFramework::Server.current.routes do\n\n get \"/\" => \"DefaultController#index\"\n\nend")
51
51
  File.write("#{projectname}/config/settings.rb","ActionFramework::Server.current.settings do |s|\n\nend")
52
52
  File.write("#{projectname}/Gemfile","source 'https://rubygems.org'\n\ngem 'actionframework'")
53
53
  File.write("#{projectname}/config.ru","require 'actionframework'\n\nrun ActionFramework::Base.new")
54
- File.write("#{projectname}/config/plugables.rb","ActionFramework::Plugables.new do \n\nend")
54
+ File.write("#{projectname}/config/plugables.rb","# Feature under development")
55
+ File.write("#{projectname}/views/layout.html.erb",File.read(ActionFramework::Gem.root.resources.templates("layout.html.erb").to_s))
56
+ File.write("#{projectname}/views/index.html.erb",File.read(ActionFramework::Gem.root.resources.templates("index.html.erb").to_s))
55
57
  system("cd #{projectname} && bundle install")
56
58
  puts "Done"
57
- puts "Run \"afw s\" to run your app"
59
+ puts "Run \"action s\" to run your app"
58
60
  end
59
61
 
60
62
  desc "Start ActionFramework server"
@@ -0,0 +1,12 @@
1
+ <img src="http://actionframework.io/rocket.png" style="height: 200px;"/>
2
+ <h1>WELCOME TO ACTIONFRAMEWORK</h1>
3
+ <p>This is the default welcome page, add a new route by:</p>
4
+ <pre>
5
+ <code>
6
+ # In config/routes.rb
7
+ ActionFramework::Server.current.routes do
8
+ get "/" => "DefaultController#index" # This route
9
+ get "/mynewroute" = "MyNewController#index" # Your new route!
10
+ end
11
+ </code>
12
+ </pre>
@@ -0,0 +1,24 @@
1
+ <html>
2
+ <head>
3
+ <link rel="stylesheet" href="http://yandex.st/highlightjs/7.5/styles/default.min.css">
4
+ <script src="http://yandex.st/highlightjs/7.5/highlight.min.js"></script>
5
+ <script>hljs.initHighlightingOnLoad();</script>
6
+ <title>Welcome to ActionFramework</title>
7
+ <link href="http://fonts.googleapis.com/css?family=Oswald:400,700" rel="stylesheet" type="text/css">
8
+ <style>
9
+ body{
10
+ background-color: black;
11
+ color: white;
12
+ font-family: 'Oswald', sans-serif;
13
+ }
14
+ p{
15
+ font-size: 20px;
16
+ }
17
+ </style>
18
+ </head>
19
+ <body>
20
+ <center>
21
+ <%= yield %>
22
+ </center>
23
+ </body>
24
+ </html>
@@ -0,0 +1,2 @@
1
+ <h1>I CAN'T FIND THAT.</h1>
2
+ <p>Our engineers our looking at the engines of to rocket to find out what happened exactly</p>
@@ -0,0 +1,24 @@
1
+ <html>
2
+ <head>
3
+ <title>We are sorry but something went wrong - ActionFramework</title>
4
+ <link href="http://fonts.googleapis.com/css?family=Oswald:400,700" rel="stylesheet" type="text/css">
5
+ <style>
6
+ body{
7
+ background-color: black;
8
+ color: white;
9
+ font-family: 'Oswald', sans-serif;
10
+ }
11
+ p{
12
+ font-size: 20px;
13
+ }
14
+ </style>
15
+ </head>
16
+ <body>
17
+ <center>
18
+ <img style="height: 300px;" src="http://actionframework.io/rocket.png" />
19
+ <%= yield %>
20
+ <p style="font-size: 14px;">Take a look at the documentation to find out how to change error pages</p>
21
+ <p>&copy; ActionFramework.io</p>
22
+ </center>
23
+ </body>
24
+ </html>
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: actionframework
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3.0
4
+ version: 0.1.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bram Vandenbogaerde
@@ -130,11 +130,10 @@ files:
130
130
  - lib/actionframework/settings.rb
131
131
  - lib/actionframework/string.rb
132
132
  - lib/actionframework.rb
133
- - lib/plugables/index.json
134
- - lib/plugables/LICENSE
135
- - lib/plugables/plugs/mongomapper.rb
136
- - lib/plugables/README.md
137
- - lib/plugables/sources.json
133
+ - resources/templates/index.html.erb
134
+ - resources/templates/layout.html.erb
135
+ - resources/views/errors/404.html.erb
136
+ - resources/views/errors/layout.html.erb
138
137
  - bin/action
139
138
  homepage: http://actionframework.io
140
139
  licenses:
@@ -1,20 +0,0 @@
1
- The MIT License (MIT)
2
-
3
- Copyright (c) 2013 actionframework
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy of
6
- this software and associated documentation files (the "Software"), to deal in
7
- the Software without restriction, including without limitation the rights to
8
- use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9
- the Software, and to permit persons to whom the Software is furnished to do so,
10
- subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- 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, FITNESS
17
- FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
18
- COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
19
- IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
20
- CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -1,4 +0,0 @@
1
- plugables
2
- =========
3
-
4
- ActionFramework Plugables
@@ -1,5 +0,0 @@
1
- {
2
- "plugs": [
3
- "mongomapper"
4
- ]
5
- }
@@ -1,5 +0,0 @@
1
- class MongoMapper < ActionFramework::Plugable:Initializer
2
- def initialize
3
-
4
- end
5
- end
@@ -1,7 +0,0 @@
1
- {
2
- "stock": [
3
- {
4
- "name": "mongomapper"
5
- }
6
- ]
7
- }