Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #10 from dbussink/master

Remove another 1% of the code
  • Loading branch information...
commit c33409c31d08d04882a9897947df1e6fa3fa5c99 2 parents f0b8418 + d68ca3b
@rkh authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  almost_sinatra.rb
View
2  almost_sinatra.rb
@@ -1,4 +1,4 @@
-%w.rack tilt backports INT TERM..map{|l|trap(l){$r.stop}rescue require l}
+%w.rack tilt INT TERM..map{|l|trap(l){$r.stop}rescue require l}
$n=Sinatra=Module.new{extend Rack;a,D,S,$p,q,Application=Builder.new,Object.method(:define_method),/@@ *([^\n]+)\n(((?!@@)[^\n]*\n)*)/m,4567,a
%w[get post put delete].map{|m|D.(m){|u,&b|a.map(u){run->(e){[200,{"Content-Type"=>"text/html"},[a.instance_eval(&b)]]}}}}
Tilt.mappings.map{|k,v|D.(k){|n,*o|$t||=(h={};File.read(caller[0][/^[^:]+/]).scan(S){|a,b|h[a]=b};h);v[0].new(*o){n=="#{n}"?n:$t[n.to_s]}.render(a,o[0].try(:[],:locals)||{})}}
Please sign in to comment.
Something went wrong with that request. Please try again.