Skip to content

Instantly share code, notes, and snippets.

View Nyoho's full-sized avatar
:octocat:
GitHubing

北䑓如法 Nyoho

:octocat:
GitHubing
View GitHub Profile
@Nyoho
Nyoho / AudioManager.cs
Created February 16, 2014 05:34 — forked from mahm/AudioManager.cs
Unity de sashimi
using UnityEngine;
using System.Collections;
public class AudioManager : SingletonMonoBehaviour<AudioManager> {
AudioClip bgm_Game;
AudioClip se_Tanpopo;
private const int source_bgm_Game = 0;
private const int maxAudio = 10;
@Nyoho
Nyoho / gem-install-mecab-ruby.sh
Created March 27, 2014 13:15
mecab-ruby を gem にしてインストールするまでの道のり
#!/bin/sh
wget https://mecab.googlecode.com/files/mecab-ruby-0.996.tar.gz
tar xvf mecab-ruby-0.996.tar.gz
cd mecab-ruby-0.996
gem build mecab-ruby.gemspec
gem install mecab-ruby
@Nyoho
Nyoho / gist:9227b6a7937e07dc6f8b
Created May 16, 2014 08:53
IP アドレス a.b.c.1 〜 a.b.c.255 の中でポート 80 番に応えてくれるものを探す (ルータモードではないアクセスポイントを探すときに使う)
for f in n.n.n.{1..255}
do
wget --spider --timeout=0.02 --tries=1 http://$f/ > /dev/null 2>&1
if [ $? -eq 0 ]; then
echo $f
fi
done
@Nyoho
Nyoho / gist:891cef0f816b896f1578
Created August 26, 2014 13:20
512x384AppleVTCompressor log
2014-08-26 22:06:35.371 CocoaSplit[315:3003] IN COMPRESSOR SETUP
[libx264 @ 0x7fd96b040400] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x7fd96b040400] profile Main, level 3.0
[libx264 @ 0x7fd96b040400] 264 - core 135 r2274 c832fe9 - H.264/MPEG-4 AVC codec - Copyleft 2003-2013 - http://www.videolan.org/x264.html - options: cabac=1 ref=1 deblock=1:0:0 analyse=0x1:0x1 me=dia subme=1 psy=1 psy_rd=1.00:0.00 mixed_ref=0 me_range=16 chroma_me=1 trellis=0 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=0 threads=12 lookahead_threads=2 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=1 keyint=60 keyint_min=6 scenecut=40 intra_refresh=0 rc_lookahead=0 rc=cbr mbtree=0 bitrate=1000 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 vbv_maxrate=1000 vbv_bufsize=1000 nal_hrd=cbr ip_ratio=1.40 pb_ratio=1.30 aq=1:1.00
2014-08-26 22:06:36.007 CocoaSplit[315:25247] ATTACHING OUTPUT
20
@Nyoho
Nyoho / Rakefile
Last active August 29, 2015 14:06
desc "Prints out your Rack middleware stack"
task :middleware do
require 'rack'
options = { config: "config.ru", environment: ENV["RACK_ENV"] || "development" }
app = Rack::Server.new(options).send(:wrapped_app)
app.tap do |mw|
while mw
if mw.class == Class #&& mw.superclass == Sinatra::Base
puts "--- (#{mw} within) ---"
mw = mw.new
@Nyoho
Nyoho / ustream-download-link-generator.js
Created October 6, 2014 01:16
A generator for download links of Ustream archives
@Nyoho
Nyoho / gist:037b98be1d0d390b65e7
Created November 18, 2014 00:15
segmentation fault
...
/Users/nyoho/Library/Saved Application State
0 swift 0x0000000103392a68 llvm::sys::PrintStackTrace(__sFILE*) + 40
1 swift 0x0000000103392f54 SignalHandler(int) + 452
2 libsystem_platform.dylib 0x00007fff905bc5aa _sigtramp + 26
3 libsystem_platform.dylib 0x0000000000000014 _sigtramp + 1873033860
4 CarbonCore 0x00007fff894d13bf CSBackupIsItemExcluded + 92
5 CarbonCore 0x00007fff894d1502 CSBackupIsItemExcluded + 415
6 CarbonCore 0x00007fff894d1502 CSBackupIsItemExcluded + 415
7 CarbonCore 0x00007fff894d1502 CSBackupIsItemExcluded + 415
@Nyoho
Nyoho / hiki-rack.org
Last active August 29, 2015 14:12
hiki rack メモ
@Nyoho
Nyoho / Many_to_something.user.js
Created February 23, 2012 11:35
"many" to "something"
// ==UserScript==
// @name Many to something
// @namespace http://kita.dyndns.org/
// @description いっぱいに対して何かをします。
// @include http://*
// @include https://*
// @exclude https://mail.google.com/*
// ==/UserScript==
function manyToSomething(){
@Nyoho
Nyoho / urlinfo-safari2org-mode
Created August 27, 2012 06:36
Safari で開いているページのタイトルとURLを org-mode 形式でさくっとコピー
-- Generate a link text in org-mode style and copy it to clipboard
tell application "Safari"
set theTitle to do JavaScript "document.title" in front document
set theURL to URL of front document
end tell
set the clipboard to "[[" & theURL & "][" & theTitle & "]]"