Entries from 2017-01-01 to 1 year
require 'sinatra'get '/' do #File.read(File.join('./public', 'index.html')) File.expand_path('index.html', settings.public_folder) end
http://dev.classmethod.jp/server-side/ruby-on-rails/sinatra__make_api_server/Why not WEBrick By default WEBrick is single threaded, single process. This means that if two requests come in at the same time, the second must wait for the firs…
http://dev.classmethod.jp/server-side/ruby-on-rails/sinatra__make_api_server/
http://qiita.com/nmrmsys/items/03f97f5eabec18a3a18bTo start a new Byobu session with a specified name: byobu new -s To change the name of a pre-existing session: byobu rename -t include the session-name in status bar for byobu-tmux $tmux s…
update rvm rvm get latest
source ~/.rvm/scripts/rvm
https://github.com/mozilla/geckodriver/releases geckodriver-v0.16.1-linux64.tar.gz$ unzip geckodriver_geckodriver-v0.16.1-linux64.tar.gz $ sudo mv geckodriver /usr/bin/ $ cd /usr/bin $ sudo chmod +x geckodriverRuby Selenium::WebDriver::Fir…
"plog" command to see the status or "ifconfig ppp0" for general interface infoConfiguration file `/etc/ppp/peers/dsl-provider'sudo apt-get install pppoe sudo ppoeconf/etc/ppp/options /etc/ppp/peers/dsl-provider sudo nano chap-secrets sudo …
Use a config file with just the indent, tidy-mark, and quiet options:indent: auto indent-spaces: 2 quiet: yes tidy-mark: no Name it tidy_config.txt and save it the same directory as the .html file. Run it like this:tidy -config tidy_config…