Skip to content

Instantly share code, notes, and snippets.

@hecomi
hecomi / gist:4411237
Created December 30, 2012 06:17
:Unite source で出てきたエラー (2012/12/30)
function <SNR>104_call_unite_empty..unite#start..<SNR>22_recache_candidates..<SNR>22_recache_candidates_loop..<SNR>22_get_source_candidates..317>
<..unite#get_all_sources..<SNR>22_initialize_sources..<SNR>22_load_default_scripts..unite#sources#versions#define..unite#sources#versions#get_so>
<urces, line 13
Vim(if):E33: No previous substitute regular expression
[unite.vim] Error occured in gather_candidates!
[unite.vim] Source name is source
@hecomi
hecomi / cppAdventCalendar.js
Last active December 10, 2015 08:18
C++ Advent Calendar 2012 を一気読みするために書いてみた
var cheerio = require('cheerio')
, request = require('request')
, RSS = require('rss')
, fs = require('fs')
;
var ADVENT_CALENDAR_URL = 'http://partake.in/events/a02d7049-1473-4b69-b5ad-25ed416c5557';
var feed = new RSS({
title : 'C++ Advent Calendar 2012',
description : '2012年最後のC++祭り',
var Julius = require('./julius.js')
, julius = new Julius("setting.jconf")
;
julius.on('onSpeechReady', function() {
console.log("onSpeechReady");
});
julius.on('onSpeechStart', function() {
console.log("onSpeechStart");
[email protected]$ node-gyp configure [~/Program/javascript/node.js/gyp]
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | x64
gyp info spawn python
gyp info spawn args [ '/Users/hecomi/.node-gyp/0.9.2/tools/gyp/gyp',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'make',
gyp info spawn args '-I',
#include <node.h>
#include <v8.h>
using namespace v8;
void init(Handle<Object> target) {
target->Set(
String::NewSymbol("hello"),
FunctionTemplate::New([](const Arguments& args)->Handle<Value> {
HandleScope scope;
{
'targets': [
{
'target_name' : 'hello',
'sources' : [ 'helloworld.cc' ],
'cflags' : ['-std=c++0x']
}
]
}
let g:quickrun_config['_'] = {
\ "hook/close_unite_quickfix/enable_hook_loaded" : 1,
\ "hook/unite_quickfix/enable_failure" : 1,
\ "hook/close_quickfix/enable_exit" : 1,
\ "hook/close_buffer/enable_failure" : 1,
\ "hook/close_buffer/enable_empty_data" : 1,
\ "hook/echo/enable" : 1,
\ "hook/echo/output_success" : "(/・ω・)/ ニャー",
\ "hook/echo/output_failure" : "(´・ω・`) ショボーン",
\ "outputter" : "multi:buffer:quickfix",
@hecomi
hecomi / julius.js
Created June 9, 2012 10:37
node.js の addon でこんなコトしたいけどやり方が思いつかない…。
// node.js addon の読み込み
var addon = require('./build/Release/julius');
var Julius = addon.Julius;
// Julius のインスタンスの生成
var julius = new Julius();
// C++ から呼べない
julius.onSpeechReady = function() {
console.log("<<< PLEASE SPEECH! >>>");
@hecomi
hecomi / shooting.js
Created May 12, 2012 07:38
だんまくさんぷる7
/* Shooting Sample
* created by @hecomi
* web: http://d.hatena.ne.jp/hecomi/
*/
$(function(){
/* ------------------------------------------------------------------------- */
// Global Parameters
/* ------------------------------------------------------------------------- */
const FPS = 30;
@hecomi
hecomi / shooting.js
Created May 11, 2012 14:06
だんまくさんぷる6
/* Shooting Sample
* created by @hecomi
* web: http://d.hatena.ne.jp/hecomi/
*/
$(function(){
/* ------------------------------------------------------------------------- */
// Global Parameters
/* ------------------------------------------------------------------------- */
const FPS = 30;