Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
require "gnuplot" | |
require "fftw3" | |
io = File.open("/bin/bash", "rb") | |
test = io.read(500000) | |
test.size # => 500000 | |
y = test.unpack("S!*") | |
x = [*0..y.size] | |
Gnuplot.open do |gp| |
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
require 'mechanize' | |
require 'twitter' | |
# Get N255 from yahoo finance | |
agent = Mechanize.new | |
agent.get('http://stocks.finance.yahoo.co.jp/stocks/detail/?code=998407.O') | |
n225 = agent.page.at("td[@class='stoksPrice']").inner_text.delete(",") | |
# Get Twitter key and token from file | |
apikey = ARGF.readlines.map! { |key| key.chomp } |
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/ruby | |
require 'rubygems' | |
require 'mechanize' | |
require 'kconv' | |
if(ARGV[0]==nil) | |
exit(0) | |
end |
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
juntaki@ubuntu ~/g/g/test> sqlite3 -header -column GPATH "select * from db;" | |
key dat extra | |
----------- ------------- ---------- | |
__.VERSION __.VERSION 2 | |
./main.c 1 | |
1 ./main.c | |
./main2.c 2 | |
2 ./main2.c | |
__.NEXTKEY 3 |
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
const reducer = (state = initialState, action) => { | |
switch (action.type) { | |
case UPDATE: | |
// update state | |
return newState; | |
default: | |
return state; | |
} | |
}; |
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
export const storeShape = PropTypes.shape({ | |
subscribe: PropTypes.func.isRequired, | |
dispatch: PropTypes.func.isRequired, | |
getState: PropTypes.func.isRequired | |
}) |
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
#!/bin/bash | |
inotifywait -q -m -e close_write articles/*.re | | |
while read -r filename event; do | |
./build-in-docker.sh | |
done |
OlderNewer