Merge branch 'benchmarks'
Before adoption: this commit came in with the history the project adopted, so no landing records it.
authored by visionmedia · committed by visionmedia · parents 5af315c, 8b7787a · Browse files · 12 files·+172 added−3 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
12 files+172 added−3 removed
- other:+172 added−3 removed
Provenance
- Commit
71e97c8- Tree
d6480ac- Author
visionmedia <tj@vision-media.ca>- Committer
visionmedia <tj@vision-media.ca>- Parent 1
5af315c- Parent 2
8b7787a
12 files changed+172 added−3 removed
added:benchmarks/express/haml.js+16 added
12345678910111213141516
require.paths.unshift('lib')require('express')require('express/plugins')
configure(function(){ enable('cache view contents') set('root', __dirname) set('views', __dirname + '/../shared')})
get('/', function(){ this.render('page.html.haml')})
run()No newline at end of fileadded:benchmarks/express/sass.js+16 added
12345678910111213141516
require.paths.unshift('lib')require('express')require('express/plugins')
configure(function(){ enable('cache view contents') set('root', __dirname) set('views', __dirname + '/../shared')})
get('/', function(){ this.render('style.css.sass', { layout: false })})
run()No newline at end of fileadded:benchmarks/shared/layout.haml+6 added
1+!!!2+%html3+ %head4+ %title Wahoo5+ %body6+ #primary= yieldadded:benchmarks/shared/layout.html.haml+6 added
1+!!!2+%html3+ %head4+ %title Wahoo5+ %body6+ #primary!= bodyadded:benchmarks/shared/page.haml+10 added
1+%h1 Some title2+%ul3+ %li a4+ %li b5+ %li c6+ %li7+ %ol8+ %li d9+ %li e10+ %li fadded:benchmarks/shared/page.html.haml+10 added
1+%h1 Some title2+%ul3+ %li a4+ %li b5+ %li c6+ %li7+ %ol8+ %li d9+ %li e10+ %li fadded:benchmarks/shared/style.css.sass+73 added
1+body2+ :font-family "Helvetica Neue", "Lucida Grande", "Arial"3+ :font-size 13px4+ :text-align center5+ :color #5556+ 7+h1, h28+ :margin 09+ :font-size 22px10+ :color #34343411+h112+ :text-shadow 1px 2px 2px #ddd13+ :font-size 60px14+ 15+img.bubble16+ :position absolute17+ :top -25px18+ :left 120px19+ 20+#wrapper21+ :position relative22+ :margin 100px auto23+ :width 500px24+ :text-align left25+ 26+ul27+ :margin 028+ :padding 029+ :max-height 300px30+ :overflow-x hidden31+ li32+ :margin 5px 033+ :padding 3px 8px34+ :list-style none35+ :border 1px solid #eee36+ li:hover37+ :cursor pointer38+ :color #2E2E2E39+40+input[type=text]41+ :padding 5px42+ :border 1px solid #ddd43+ :outline none44+input[type=text]:focus45+ :border-color #00C3FF46+47+input[type=submit]48+ :padding 6px 10px49+ :border solid 1px #99950+ :background -webkit-gradient(linear, 0% 0%, 0% 100%, from(#fff), to(#ddd))51+ :color #33352+ :text-decoration none53+ :cursor pointer54+ :display inline-block55+ :text-align center56+ :text-shadow 0px 1px 1px #fff57+ :line-height 158+input[type=submit]:hover59+ :background -webkit-gradient(linear, 0% 0%, 0% 100%, from(#fff), to(#E6E4E4))60+input[type=submit]:active61+ :background -webkit-gradient(linear, 0% 0%, 0% 100%, from(#fff), to(#c7c7c7))62+input[name=name]63+ :width 80px64+ 65+a66+ :color #1ABFF167+a:hover68+ :padding 0 5px69+a:hover:before70+ :content 'visit: '71+ 72+#online73+ :font-size 12pxadded:benchmarks/thin/haml.ru+14 added
1+2+require 'rubygems'3+require 'sinatra'4+require 'haml'5+6+configure do7+ set 'views', File.dirname(__FILE__) + '/../shared'8+end9+10+get '/' do11+ haml :page, :ugly => true12+end13+14+run Sinatra::Applicationadded:benchmarks/thin/sass.ru+14 added
1+2+require 'rubygems'3+require 'sinatra'4+require 'sass'5+6+configure do7+ set 'views', File.dirname(__FILE__) + '/../shared'8+end9+10+get '/' do11+ sass :'style.css'12+end13+14+run Sinatra::Applicationmodified:benchmarks/graph+1 added-1 removed
53 unmodified lines54 }55 56 mkdir -p benchmarks/graphs57 58-for type in simple static static.large; do58+for type in simple haml sass static static.large; do59 plot=benchmarks/graphs/$type.p60 log generating benchmarks/graphs/$type.png61 line $type \62 node/$type.js.dat \22 unmodified linesmodified:benchmarks/run+5 added-1 removed
50 unmodified lines51 bm node static.large.js52 bm express simple.js53 bm express static.js54 bm express static.large.js55+bm express haml.js56+bm express sass.js57 bm thin simple.ru58 bm thin static.ru57-bm thin static.large.ru59+bm thin static.large.ru60+bm thin haml.ru61+bm thin sass.rumodified:lib/express/request.js+1 added-1 removed
117 unmodified lines118 */119 120 accepts: function() {121 var accept = this.header('accept')122- if (!accept) return true122+ if (!accept || accept === '*/*') return true123 return arguments.any(function(path){124 var type = mime.type(path)125 return accept.indexOf(type) !== -1 ||126 accept.indexOf(type.split('/')[0] + '/*') !== -1284 unmodified lines