tyrone 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +21 -4
- data/bin/tyrone +18 -0
- data/deps.rip +1 -0
- data/lib/tyrone.rb +22 -3
- data/templates/config.ru.erb +14 -0
- data/templates/reset.sass.erb +57 -0
- data/templates/sinatra.rb.erb +17 -0
- metadata +18 -4
data/README.md
CHANGED
@@ -1,8 +1,8 @@
|
|
1
|
-
|
1
|
+
![tyrone](http://github.com/chrislloyd/tyrone/raw/master/logo.png)
|
2
2
|
|
3
|
-
tyrone be great with uis. he loves em so much and will care the shit out of them. my boy tyrone is definitely the right man for the job, i aint playin
|
3
|
+
<small>a rapid prototyping fix. tyrone be great with uis. he loves em so much and will care the shit out of them. my boy tyrone is definitely the right man for the job, i aint playin. by [chris](http://chrislloyd.com.au).</small>
|
4
4
|
|
5
|
-
![
|
5
|
+
![screenshot](http://cloud.github.com/downloads/chrislloyd/tyrone/tyrone-0.1.0.png)
|
6
6
|
|
7
7
|
## employing tyrone
|
8
8
|
|
@@ -28,7 +28,24 @@ if you be a real player, you can knock out the old shit and add da new shit:
|
|
28
28
|
require 'tyrone'
|
29
29
|
get '/my-action' { ... }
|
30
30
|
|
31
|
-
|
31
|
+
## associates
|
32
32
|
|
33
33
|
* [b-webstar](http://plus2.com.au) for his playground system what.
|
34
34
|
* [p-oye](http://github.com/philoye) for makin rehearsals.
|
35
|
+
|
36
|
+
## givin' back
|
37
|
+
|
38
|
+
fork the project, submit a pull request and I'll get to it straight away. or you can just checkout the source by running:
|
39
|
+
|
40
|
+
git clone git://github.com/chrislloyd/tyrone.git
|
41
|
+
|
42
|
+
## license
|
43
|
+
|
44
|
+
Copyright (c) 2009 Chris Lloyd.
|
45
|
+
|
46
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
47
|
+
|
48
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
49
|
+
|
50
|
+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
51
|
+
|
data/bin/tyrone
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
require 'rubygems'
|
3
|
+
|
4
|
+
gem 'pixii', '>= 0.1.0'
|
5
|
+
require 'pixii'
|
6
|
+
|
7
|
+
Pixii.called(:tyrone) do |make, opts|
|
8
|
+
make.dir 'features', 'mockups', 'public', 'public/js', 'public/images', 'public/css'
|
9
|
+
|
10
|
+
make.clone 'http://github.com/toolmantim/states.js/raw/master/states.js', 'public/js/states.js'
|
11
|
+
make.clone 'http://jqueryjs.googlecode.com/files/jquery-1.3.2.min.js', 'public/js/jquery.js'
|
12
|
+
|
13
|
+
make.template 'sinatra.rb.erb', "#{opts.project}.rb"
|
14
|
+
make.template 'config.ru.erb', 'config.ru'
|
15
|
+
make.template 'reset.sass.erb', 'public/css/reset.sass'
|
16
|
+
|
17
|
+
make.magic!
|
18
|
+
end
|
data/deps.rip
CHANGED
data/lib/tyrone.rb
CHANGED
@@ -1,9 +1,14 @@
|
|
1
1
|
gem 'haml', '2.2.2'; require 'haml'; require 'sass'
|
2
2
|
|
3
|
+
set :haml => {:format => :html5}
|
4
|
+
|
3
5
|
helpers do
|
4
6
|
def mockup_path(mockup)
|
5
7
|
"/mockups/#{mockup.gsub(' ','_')}"
|
6
8
|
end
|
9
|
+
def hidden
|
10
|
+
{:style => 'display:none'}
|
11
|
+
end
|
7
12
|
end
|
8
13
|
|
9
14
|
get '/' do
|
@@ -18,6 +23,17 @@ get '/mockups/:mockup' do |mockup|
|
|
18
23
|
haml mockup.to_sym
|
19
24
|
end
|
20
25
|
|
26
|
+
# Sass doesn't belong in mockups, it belongs in public
|
27
|
+
|
28
|
+
get /^\/css\/(.+)\.css$/ do |style_file|
|
29
|
+
sass_file = File.join('public','css',"#{style_file}.sass")
|
30
|
+
pass unless File.exist?(sass_file)
|
31
|
+
content_type :css
|
32
|
+
sass File.read(sass_file)
|
33
|
+
end
|
34
|
+
|
35
|
+
get /\.sass$/ { pass }
|
36
|
+
|
21
37
|
__END__
|
22
38
|
|
23
39
|
@@index
|
@@ -43,12 +59,13 @@ __END__
|
|
43
59
|
:color #CCC
|
44
60
|
:font-size 12px
|
45
61
|
:line-height 20px
|
62
|
+
:font-size 14px
|
63
|
+
:line-height 20px
|
64
|
+
:color #999
|
65
|
+
:text-transform lowercase
|
46
66
|
a
|
47
67
|
:text-decoration none
|
48
|
-
:font-size 14px
|
49
68
|
:color #333
|
50
|
-
:line-height 20px
|
51
|
-
:text-transform lowercase
|
52
69
|
&:hover
|
53
70
|
:border-bottom 1px solid #333
|
54
71
|
.footer
|
@@ -61,6 +78,8 @@ __END__
|
|
61
78
|
%body
|
62
79
|
%h1 Mockups
|
63
80
|
%ul
|
81
|
+
- if @mockups.empty?
|
82
|
+
There are no mockups yet. Add one in <code>/mockups</code>.
|
64
83
|
- @mockups.each do |mockup|
|
65
84
|
%li
|
66
85
|
%a{:href => mockup_path(mockup)}= mockup
|
@@ -0,0 +1,14 @@
|
|
1
|
+
require 'sinatra'
|
2
|
+
|
3
|
+
__DIR__ = File.dirname(__FILE__)
|
4
|
+
|
5
|
+
set :run => false,
|
6
|
+
:environment => :development,
|
7
|
+
:root => __DIR__,
|
8
|
+
:views => File.join(__DIR__, 'mockups'),
|
9
|
+
:public => File.join(__DIR__, 'public'),
|
10
|
+
:app_file => '<%= project %>.rb'
|
11
|
+
|
12
|
+
require '<%= project %>.rb'
|
13
|
+
|
14
|
+
run Sinatra::Application
|
@@ -0,0 +1,57 @@
|
|
1
|
+
html,body,div,span,object,iframe,h1,h2,h3,h4,h5,h6,a,p,blockquote,pre,abbr,address,cite,code,del,dfn,em,img,ins,kbd,q,samp,small,strong,sub,sup,var,b,i,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,dialog,figure,footer,header,hgroup,menu,nav,section,menu,time,mark,audio,video
|
2
|
+
:margin 0
|
3
|
+
:padding 0
|
4
|
+
:border none
|
5
|
+
:outline 0
|
6
|
+
:font-size 100%
|
7
|
+
:vertical-align baseline
|
8
|
+
:background transparent
|
9
|
+
|
10
|
+
body
|
11
|
+
:line-height 1
|
12
|
+
|
13
|
+
article, aside, dialog, figure, footer, header, hgroup, nav, section
|
14
|
+
:display block
|
15
|
+
|
16
|
+
ol, ul
|
17
|
+
:list-style none
|
18
|
+
|
19
|
+
blockquote, q
|
20
|
+
:quotes none
|
21
|
+
|
22
|
+
blockquote:before,blockquote:after,q:before,q:after
|
23
|
+
:content ''
|
24
|
+
:content none
|
25
|
+
|
26
|
+
*:focus
|
27
|
+
:outline 0
|
28
|
+
|
29
|
+
ins
|
30
|
+
:text-decoration none
|
31
|
+
|
32
|
+
mark
|
33
|
+
:font-style italic
|
34
|
+
:font-weight bold
|
35
|
+
|
36
|
+
del
|
37
|
+
:text-decoration line-through
|
38
|
+
|
39
|
+
abbr[title], dfn[title]
|
40
|
+
:border-bottom 1px dotted #000
|
41
|
+
:cursor help
|
42
|
+
|
43
|
+
table
|
44
|
+
:border
|
45
|
+
:collapse collapse
|
46
|
+
:spacing 0
|
47
|
+
|
48
|
+
hr
|
49
|
+
:display block
|
50
|
+
:height 1px
|
51
|
+
:border 0
|
52
|
+
:border-top 1px solid #cccccc
|
53
|
+
:margin 1em 0
|
54
|
+
:padding 0
|
55
|
+
|
56
|
+
input, select
|
57
|
+
:vertical-align middle
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# Tyrone - It'll care the shit out of you
|
2
|
+
require 'tyrone'
|
3
|
+
|
4
|
+
helpers do
|
5
|
+
def hidden
|
6
|
+
{:style => 'display:none'}
|
7
|
+
end
|
8
|
+
end
|
9
|
+
|
10
|
+
set :haml => {:format => :html5}
|
11
|
+
|
12
|
+
get /^\/(.+)\.css$/ do |style_file|
|
13
|
+
sass_file = File.join('public',"#{style_file}.sass")
|
14
|
+
pass unless File.exist?(sass_file)
|
15
|
+
content_type :css
|
16
|
+
sass File.read(sass_file)
|
17
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tyrone
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chris Lloyd
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date:
|
12
|
+
date: 2009-08-02 00:00:00 +10:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -32,10 +32,20 @@ dependencies:
|
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: 2.2.2
|
34
34
|
version:
|
35
|
+
- !ruby/object:Gem::Dependency
|
36
|
+
name: pixii
|
37
|
+
type: :runtime
|
38
|
+
version_requirement:
|
39
|
+
version_requirements: !ruby/object:Gem::Requirement
|
40
|
+
requirements:
|
41
|
+
- - ">="
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
version: 0.1.0
|
44
|
+
version:
|
35
45
|
description:
|
36
46
|
email: christopher.lloyd@gmail.com
|
37
|
-
executables:
|
38
|
-
|
47
|
+
executables:
|
48
|
+
- tyrone
|
39
49
|
extensions: []
|
40
50
|
|
41
51
|
extra_rdoc_files: []
|
@@ -45,6 +55,10 @@ files:
|
|
45
55
|
- Rakefile
|
46
56
|
- README.md
|
47
57
|
- lib/tyrone.rb
|
58
|
+
- bin/tyrone
|
59
|
+
- templates/config.ru.erb
|
60
|
+
- templates/reset.sass.erb
|
61
|
+
- templates/sinatra.rb.erb
|
48
62
|
has_rdoc: true
|
49
63
|
homepage: http://github.com/chrislloyd/tyrone
|
50
64
|
licenses: []
|