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
LeftDiamond := False | |
AltTab := False | |
RightDiamond := False | |
Vim := False | |
VimRepeat := 0 | |
;; 不慮の事態に備えて起動時/リロード時に Windows キーを解放 | |
Send, {LWin up} |
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
<?php | |
if (empty($_REQUEST['since_id'])) { | |
$since_id = 0; | |
} else { | |
$since_id = (int)$_REQUEST['since_id']; | |
} | |
$db = new PDO("pgsql:...", 'user', 'pass', array( | |
PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION, |
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
// ==UserScript== | |
// @name Instant Move | |
// @namespace http://cryks.hateblo.jp/ | |
// @description Enable move button on Instant Upload album. | |
// @match https://picasaweb.google.com/lh/reorder* | |
// ==/UserScript== | |
(function() { | |
var move = document.getElementById('lhid_move'); | |
var enableButton = document.createElement('button'); |
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
diff --git a/lib/dbi.scm b/lib/dbi.scm | |
index e717908..5c52bc1 100644 | |
--- a/lib/dbi.scm | |
+++ b/lib/dbi.scm | |
@@ -226,16 +226,21 @@ | |
;; when called with binding values to the parameters. | |
(define (dbi-prepare-sql conn sql) | |
(let* ((tokens (sql-tokenize sql)) | |
- (num-params (count (lambda (elt) | |
- (match elt |
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
(use srfi-60) | |
(use gauche.generator) | |
(define (gappend-map proc . gens) | |
(generate | |
(^[yield] | |
(generator-for-each | |
(pa$ for-each yield) | |
(apply gmap proc gens))))) |
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
(use control.thread-pool) | |
(use gauche.threads) | |
(let ([t (thread-start! (make-thread (cut undefined)))] | |
[pool (make-thread-pool 10)]) | |
(terminate-all! pool) | |
(thread-terminate! t)) |
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
(use makiki) | |
(define-http-handler #// | |
(^[req app] | |
(undefined))) | |
(start-http-server :port 8889) |
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
" Vim syntax file | |
" Language: Scheme (R5RS) | |
" Last Change: 2007 Jun 16 | |
" Maintainer: Sergey Khorev <sergey.khorev@gmail.com> | |
" Original author: Dirk van Deun <dirk@igwe.vub.ac.be> | |
" Modifier: yamada <yamada-remove-this-part@tir.jp> | |
" ( http://e.tir.jp/wiliki?vim:scheme.vim ) | |
" $Id$ |
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 gosh | |
(use gauche.generator) | |
(use rfc.md5) | |
(define (main argv) | |
(let ([lis (make-hash-table 'string=?)]) | |
(dolist [file (filter file-is-regular? (glob "md5/*.md5"))] | |
(do-generator [line (file->line-generator file)] | |
(rxmatch-case line |
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
(define (gglob2 patterns . opts) | |
(define (cont) | |
(let/cc outer-cont | |
(apply glob-fold patterns | |
(lambda (curr _) | |
(let/cc inner-cont | |
(set! cont inner-cont) | |
(outer-cont curr))) | |
'() opts) | |
(set! cont (lambda () (eof-object))) |
NewerOlder