This file contains 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
enum { | |
UIButtonColorsTan, | |
UIButtonColorsBlack, | |
UIButtonColorsGreen, | |
UIButtonColorsOrange, | |
UIButtonColorsBlue, | |
UIButtonColorsWhite, | |
UIButtonColorsGrey | |
}; |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>RESTEST</title> | |
<link rel='stylesheet' href='http://yui.yahooapis.com/3.8.1/build/cssreset/cssreset-min.css'> | |
<style> | |
html { | |
font:12px monospace; | |
background: #FBFBFB; | |
} |
This file contains 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
#!/usr/bin/env coffee | |
fs = require 'fs' | |
path = require 'path' | |
util = require 'util' | |
{exec} = require 'child_process' | |
unless fs.existsSync 'package.json' | |
console.log 'Not found `package.json`' | |
process.exit 1 |
This file contains 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
# 全プロセスで共通して実行される | |
os = require 'os' | |
http = require 'http' | |
cluster = require 'cluster' | |
# 親プロセス起動時に一回だけ呼ばれる | |
if cluster.isMaster | |
console.log 'starting...' | |
# 起動したosのcpuのスレッド数を求める |
This file contains 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
fs = require 'fs' | |
path = require 'path' | |
app = require('http').createServer (req, res) -> | |
res.writeHead 200, 'Content-Type': 'text/html' | |
res.end fs.readFileSync (path.resolve 'public', 'index.html'), 'utf-8' | |
app.listen 3000 | |
require('socket.io').listen(app).on 'connection', (socket) -> |
This file contains 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
stat = 0 | |
try | |
json = JSON.parse process.argv[2] | |
unless json.length is 2 | |
throw (new Error 'short length') | |
catch e | |
console.error e | |
stat = 1 |
This file contains 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
{print} = require 'util' | |
for i in [1...101] | |
fizz = i % 3 is 0 | |
buzz = i % 5 is 0 | |
print 'Fizz' if fizz | |
print 'Buzz' if buzz | |
print i if !fizz and !buzz | |
print '\n' |
This file contains 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
{ | |
"color_scheme": "Packages/Color Scheme - Default/Smyck.tmTheme", | |
"font_face": "Yutapon", | |
"font_size": 11.0, | |
"highlight_modified_tabs": true, | |
"ignored_packages": | |
[ | |
"Vintage" | |
], | |
"rulers": |
This file contains 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
--prefix=/usr/local | |
--http-client-body-temp-path=/usr/local/tmp/nginx/client | |
--http-proxy-temp-path=/usr/local/tmp/nginx/proxy | |
--http-fastcgi-temp-path=/usr/local/tmp/nginx/fastcgi | |
--conf-path=/usr/local/etc/nginx/nginx.conf | |
--pid-path=/usr/local/var/run/nginx.pid | |
--http-log-path=/usr/local/var/log/nginx/access.log | |
--error-log-path=/usr/local/var/log/nginx/error.log | |
--with-http_dav_module | |
--with-http_mp4_module |
This file contains 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
upstream favorymous { | |
server 127.0.0.1:3032; | |
} | |
server { | |
listen 80; | |
charset UTF-8; | |
server_name favorymous.com; | |
root /var/www/com.favorymous.www/public; |