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
package sysprop; | |
import java.util.Iterator; | |
import java.util.Map.Entry; | |
import java.util.Properties; | |
public class Dump { | |
public static void main(String[] args) { | |
Properties properties = System.getProperties(); |
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
awt.nativeDoubleBuffering=true | |
awt.toolkit=apple.awt.CToolkit | |
file.encoding=UTF-8 | |
file.encoding.pkg=sun.io | |
file.separator=/ | |
ftp.nonProxyHosts=local|*.local|169.254/16|*.169.254/16 | |
gopherProxySet=false | |
http.nonProxyHosts=local|*.local|169.254/16|*.169.254/16 | |
java.awt.graphicsenv=apple.awt.CGraphicsEnvironment | |
java.awt.printerjob=apple.awt.CPrinterJob |
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
+{ | |
mysql => { | |
user => 'volt', | |
password => 'voltisfast', | |
}, | |
} |
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
nginx -V 2>&1 | sed 's/--/\n--/g' | |
### or using perl | |
### nginx -V 2>&1 | perl -pe 's/--/\n--/g' |
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
#!/usr/bin/env perl | |
use strict; | |
use warnings; | |
use feature qw(say); | |
my @lines; | |
while (<>) { | |
chomp; | |
next unless $_; | |
push @lines, $_; |
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
// using static methods | |
console.log(Date.now()); // 1357662789317 | |
// if you have Date objects | |
console.log(new Date().getTime()); // 1357662789317 | |
// numeric context | |
console.log(+new Date); // 1357662789317 | |
console.log(+new Date()); // 1357662789317 |
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
create database tweets_importer character set utf8; | |
create table user_timeline( | |
id int(10) auto_increment | |
,uid int(10) not null | |
,name varchar(255) not null | |
,text varchar(255) not null | |
,source varchar(255) not null | |
,retweet_count int(10) not null | |
,favorited int(1) not null | |
,retweeted int(1) not null |
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
var obj = (function() { | |
var _canvas = 'canvas'; | |
function _radian(x) { | |
return x * Math.PI / 180; | |
} | |
// public api | |
return { | |
canvas: _canvas, | |
radian: _radian |
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
/* | |
平山尚『ゲームプログラマになる前に覚えておきたい技術』より | |
お題:荷物運びゲームを2時間以内につくる | |
*/ | |
#include<iostream> | |
using namespace std; | |
char screen[5][8] = { |
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
find . -name "*.php" -exec rm -v {} \; | tee /dev/tty | wc -l |