Created
September 27, 2013 09:26
-
-
Save rummelonp/6726153 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source 'https://rubygems.org' | |
gem 'sinatra' | |
gem 'puma' | |
gem 'thin' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
require 'sinatra' | |
require 'puma' | |
set :server, :puma | |
get '/' do | |
string = 'にゃーん' | |
stream do |out| | |
loop do | |
out << string += '!' | |
out << "\r\n" | |
sleep 1 | |
end | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
require 'sinatra' | |
require 'thin' | |
set :server, :thin | |
get '/' do | |
string = 'にゃーん' | |
stream do |out| | |
loop do | |
out << string += '!' | |
out << "\r\n" | |
sleep 1 | |
end | |
end | |
end |
Author
rummelonp
commented
Sep 27, 2013
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment