GitHubindexHello source: index.md View on github | Report issue Generated by middleman 3.1.6. Powered by Ruby 2.2.2.
èªãµã¼ãã¹ãç¶ã ã¨Sinatraã£ã¦ã¾ãã ãã®éãããã©ã¼ãã³ã¹ã¢ãããçããMemcached(+memcache-client)ãå©ç¨ãããRailsã®ãã©ã°ã¡ã³ããã£ãã·ã¥ã©ã¤ã¯ã«ä½¿ããExtensionãæ¸ãã¾ããã 使ãæ¹ãã³ã¼ãã¯ã³ãã©ã«ããã¾ã http://github.com/gioext/sinatra-memcache/tree/master 使ãæ¹ # start memcached cd myapp git clone git://github.com/gioext/sinatra-memcache.git lib/sinatra-memcache# app.rb require 'rubygems' require 'sinatra' require File.dirname(__FILE__) + '/lib/sinatra-memcache/lib/sin
2. Ruby Sapporo Night vol.102009-04-17(Fri.) Apple Store, Sapporo Rubyæå¹ Local PHPé¨ ã¯ãã¹ã³ãã¥ããã£ä¼ç» - 2 3. Sinatra㧠鼻æã¾ããã® Webéçº ãã ã ããã SHIDARA Yohji æ¥æ¬Rubyã®ä¼ Rubyæå¹ Web development with Sinatra humming a tune. 2009-04-17 Ruby Sapporo Night vol. 10 ã¢ããã«ã¹ãã¢æå¹ 5. è¨æ¨ æ´ç¾ / SHIDARA Yohji / dara â£dara@ruby-sapporo.org â£http://friendfeed.net/dara â£æå¹çã¾ã, æå¹è²ã¡, æå¹å¤§å¥½ã â£ã¹ã¼ãã«ã¬ã¼å¤§å¥½ã â£Rubyæå¹ éå¶ãã¼ã â£RubyKaigi2008 å®
å æ¥ Sinatra ã CGI ã§åãããã¨ãã¦ã¨ã©ã¼*1ãçºçããããã¦æããã£ã¦ããããããã£ã¨ããåãããã«ãªã£ãã®ã§ã¡ããã¾ã¨ãã ãã£ãã㨠ãã£ã¬ã¯ããªæ§æ ãã¸ãã¯ããã³ãã¬é¨å㯠DocumentRoot ä¸ã«ã¯ç½®ããªãæ¹éã§ã /home/***/www/ # => DocumentRoot /home/***/www/test/index.cgi # => ããã«ã¢ã¯ã»ã¹ /home/***/www/.htaccess # => .htã¢ã¯ã»ã¹ /home/***/sites/test/test.rb # => ãã¸ã㯠/home/***/sites/test/views/index.haml # => HTMLãã³ã㬠/home/***/sites/test/views/test.sass # => CSSãã³ã㬠/home/***/local/lib/rub
å人çã«Sinatraã¨Limonadeããã¤ãã¼ã ãªã®ã§ãããSinatraã«é¢ãã¦è¨ãã°ãCGIã§åããæ¹æ³ã¯(æ¬å®¶ã®ããã¥ã¡ã³ãã¨ãã§ã¯)ãã¾ããã©ãã¼ããã¦ããªãããã§ããå½å ã§ã¯ãããªãã«è¨äºããããããªã®ã§ãããçµå±ã½ã¼ã¹ã«æãå ¥ãã¦ãã¾ãï¼Sinatraã®ã½ã¼ã¹ã«ãRack::Handler::CGI.runãããã¿ã«æ¸ãï¼ããrackupã§å®è¡ããæ¹æ³ããå¤ãããã§ããåè ã¯CGIå°ç¨ã«ãªã£ã¦ãã¾ãã®ã§ãã¾ãã¡ã ããå¾è ã¯ã·ã§ã«ãï¼åå®è¡ãããã®ãã©ãã«ãç¾ããããã¾ããï¼ç¾å®çã«ã¯ãã¾ãåé¡ã«ãªããªãã®ããããã¾ãããï¼ã ããã§ããããããã£ã¦ã¿ãã¨ãããä½ã¨ãè¯ãããªæ¹æ³ãã§ãã¾ããã ã¾ãSinatraã®ã½ã¼ã¹ãé©å½ã§ãã require 'rubygems' require 'sinatra' set :run, true get '/?' do "hello"
ãã«ã¹ã¿ãã¯ãã¦ãªã®Railsãããã¾ã§å¿ è¦ãªãããã¨ãERBã§ã´ãªã´ãªãã¡ã³ãã¯ã»ã¼ããã£ã±ãRailsã§ããªã©ã¨ãé½ã¯ã¾ãã®ã¼ããããããã¦ã¼ãããRubyã®Webãã¬ã¼ã ã¯ã¼ã¯ã¯ä»ã«ããããã©ãã軽ãã¦ãããã ãPHPã使ããããªãã ããªãã ã ãããªæ©ã¾ããã解æ¶ãã¦ããããã¬ã¼ã ã¯ã¼ã¯ãçºè¦ãã¦ãã¾ãã¾ããããSinatraãã§ãããã¾ããããã¤ã¯ã軽ããã ã Sinatra ãµã¤ãã®ããããã¼ã¸ã«æ¸ããã¦ããã³ã¼ãããããããµã¯ãµã¯æããããåºãã¦ããã¦ãã¾ãã require 'rubygems' require 'sinatra' get '/hi' do "Hello World!" end 説æèªã¾ãªãã¦ã解ãããããã æ¥æ¬èªã®è§£èª¬ã¹ã©ã¤ããããã¾ãããã解ã解説ã¼ã å ¬å¼ãµã¤ãã®READMEãèªãã°ãã ãããOKã Sinatra: README ãã©ã¡ã¼ã¿ãåå¾ã
longkey1.net 2024 èä½æ¨©. ä¸è¨±è¤è£½ ãã©ã¤ãã·ã¼ããªã·ã¼
Table of Contents Open Table of Contents Sinatra ã¨ã¯ Sinatra ã®ç¹å¾´ ãªã½ã¼ã¹æå(RESTFul)/URI ããã¤ã¬ã¯ãã« Ruby ã³ã¼ãã«ç´ä»ã Rack ãã¼ã¹ã§ãã ææ³ åèãµã¤ã Sinatra ã¨ã¯ Rack ã調ã¹ã¦ããéãRuby ã§æ¸ããã軽éãã¬ã¼ã ã¯ã¼ã¯ Sinatra ã Rack ããã¼ã¹ã«æ¸ããã¦ããã¨ç¥ããããã§ãSinatra ãã¡ãã£ã¨ç¢ºèªãã¦ã¿ãã Sinatra Sinatra ã¯ãWeb ã¢ããªã±ã¼ã·ã§ã³ãä½ãéã®è»½ãã®ã¤ã³ãã¯ãã§å¤§ãã話é¡ãããã£ããã¡ãªã¿ã«ãâHello World!!â Web ã¢ããªã±ã¼ã·ã§ã³ã¯ä»¥ä¸ã®è¨è¿°ã ãã§æ¸ãã hello_world.rb: require 'rubygems' require 'sinatra' get '/' do "Hello Wor
GT Nitro: Car Game Drag Raceã¯ãå ¸åçãªã«ã¼ã²ã¼ã ã§ã¯ããã¾ãããããã¯ã¹ãã¼ãããã¯ã¼ãã¹ãã«å ¨éã®ã«ã¼ã¬ã¼ã¹ã²ã¼ã ã§ãããã¬ã¼ãã¯å¿ãã¦ãããã¯ãã©ãã°ã¬ã¼ã¹ããã¤ãã¼ï¼å¤å ¸çãªã¯ã©ã·ãã¯ããæªæ¥çãªãã¼ã¹ãã¾ã§ãæãã¯ã¼ã«ã§éãè»ã¨ã«ã¼ã¬ã¼ã¹ã§ãã¾ããã¹ãã£ãã¯ã·ããããã¹ã¿ã¼ããããããè³¢ã使ã£ã¦ç«¶äºãæã¡ç ´ãå¿ è¦ãããã¾ãããã®ã«ã¼ã¬ã¼ã¹ã²ã¼ã ã¯ãã®ãªã¢ã«ãªç©çå¦ã¨ç´ æ´ãããã°ã©ãã£ãã¯ã¹ã§ããªãã®å¿ãççºããã¾ããããã¾ã§ãã¬ã¤ãããã¨ã®ãªããããªãã®ã§ãã GT Nitroã¯ããªãã¬ãã¯ã¹ã¨ã¿ã¤ãã³ã°ã試ãã«ã¼ã¬ã¼ã¹ã²ã¼ã ã§ããæ£ããç¬éã«ã®ã¢ãã·ããããã¬ã¹ãæãåãè¸ãå¿ è¦ãããã¾ããã¾ãã大ç©ãã¡ã¨ç«¶ãã¤ã¤ãè»ã®ãã¥ã¼ãã³ã°ã¨ã¢ããã°ã¬ã¼ããè¡ããªããã°ãªãã¾ãããä¸çä¸ã§æé«ã®ãã©ã¤ãã¼ã¨è»ã¨ã«ã¼ã¬ã¼ã¹ã«æããã¨ã«ãªãããã©ãã°ã¬ã¼ã¹ã®çå
This page is also available in English. å§ããã Sinatraã¯Rubyã§ä¸è¨ã®ãããªæå°å´åã§ææ©ãã¦ã§ãã¢ããªã±ã¼ã·ã§ã³ãä½æããããã®DSLã§ãã # myapp.rb require 'rubygems' require 'sinatra' get '/' do 'Hello world!' end gemãã¤ã³ã¹ãã¼ã«ãã¦åããã¦ã¿ãã sudo gem install sinatra ruby myapp.rb localhost:4567 ãè¦ãã ã«ã¼ã Sinatraã§ã¯ãã«ã¼ãã¯HTTPã¡ã½ããã¨URLãããã³ã°ãã¿ã¼ã³ããã¢ã«ãªã£ã¦ãã¾ãã ã«ã¼ãã¯ãããã¯ã«çµã³ä»ãããã¦ãã¾ãã get '/' do .. ä½ãè¦ãã .. end post '/' do .. ä½ãçæãã .. end put '/' do .. ä½ãæ´
ç¡æãªã®ã¯ééããªãããï¼ããããï¼æéã«ãã¦ããã¨ããããã½ã éæ³ä½¿ãã«å¿ è¦ãªãã® åºæ¬çãªRubyã®ç¥è åºæ¬çãªhttp, htmlã«é¢ããç¥è Googleã¢ã«ã¦ã³ã éæ³ä½¿ãã«å¿ è¦ã§ãªããã® èªå® ãµã¼ã ã¬ã³ã¿ã«ãµã¼ã MVCã¨ãDBã¨ãã®ç¥è åæ ã¢ããªã±ã¼ã·ã§ã³ã¯Google App Engine(Java)ã®ä¸ã§åãã JRuby+Sinatraã§æ§æãJRubyã¯Javaä»®æ³ãã·ã³ä¸ã®Rubyå®è¡ç°å¢ã®ãã¨ã§ãSinatraã¯Rubyã®è¶ ãæ軽ã»è»½éWebãã¬ã¼ã ã¯ã¼ã¯ã ãããããå§ãã¾ãã俺ã®ç°å¢ãLinuxãªã®ã§ãWinãMacã使ã£ã¦ãæ¹ã¯é©å®èªã¿æ¿ãã¦ãã ï¼ãã¾ãGoogle App Engineã®ã¢ã«ã¦ã³ããåå¾ãããã¢ããªã±ã¼ã·ã§ã³ãé©å½ã«ç»é²ããã Googleã®ã¢ã«ã¦ã³ãããªã人ã¯ã¾ããããããæ¢ã«æã£ã¦ã人ã¯Google App Engineã«ç»
ã©ã³ãã³ã°
ã©ã³ãã³ã°
ã©ã³ãã³ã°
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}