Skip to content

Instantly share code, notes, and snippets.

@mattn
mattn / README.md
Last active February 14, 2017 15:13
jsonstore vs bolt
c:\dev\go-sandbox\jsonstore>go test -bench . -count 10
goos: windows
goarch: amd64
BenchmarkJsonstore-4        2000            897051 ns/op
BenchmarkJsonstore-4        2000            885050 ns/op
BenchmarkJsonstore-4        2000           1131564 ns/op
BenchmarkJsonstore-4        2000            839048 ns/op
BenchmarkJsonstore-4        2000            919052 ns/op
BenchmarkJsonstore-4        2000            838547 ns/op
@isdyy
isdyy / gae-request-routing-rules-and-tasks.md
Last active December 4, 2016 05:39
GAE: Modules のリクエストルーティング, TaskQueue のTask 実行モジュールとバージョンについて

Modules のリクエストルーティング, TaskQueue のTask 実行モジュールとバージョンについて (2015.06)

Basics

リクエストのルーティングについて:

https://cloud.google.com/appengine/docs/python/modules/routing

  1. URLによるモジュール・バージョン(・インスタンス)指定
    • URL で module, version (, instance) を指定できる.
  • URL に module, version (, instance) を併記した指定は、dispatch.yaml の指定より優先される.
@zchee
zchee / actionlist.vim
Last active April 19, 2024 13:22
IdeaVim actionlist
--- Actions ---
$Copy <M-C>
$Cut <M-X> <S-Del>
$Delete <Del> <BS> <M-BS>
$LRU
$Paste <M-V>
$Redo <M-S-Z> <A-S-BS>
$SearchWeb <A-S-G>
$SelectAll <M-A>
$Undo <M-Z>
@shinyaohira
shinyaohira / Auto Layout Guide.md
Last active November 23, 2019 14:50
Auto Layout Guide
use strict;
use warnings;
use Plack::Request;
use Plack::MIME;
use Plack::App::Directory;
use FindBin;
my $java_bin = `which java` =~ s/[\n\r]//gr
or die 'Install Java :(';
@hirose31
hirose31 / jsx
Created June 12, 2012 08:53 — forked from ywatase/jsx
_jsx()
{
local cur prev
COMPREPLY=()
cur=${COMP_WORDS[COMP_CWORD]}
prev=${COMP_WORDS[COMP_CWORD-1]}
JSX_OPTIONS='\
--add-search-path\
--executable\
--run\
@azu
azu / jquery.disableSelection.js
Created December 9, 2011 08:10
要素を選択範囲にできないようにする
(function ($) {
$.fn.disableSelection = function () {
return this.each(function () {
$(this).attr('unselectable', 'on')
.css({'-moz-user-select':'none',
'-o-user-select':'none',
'-khtml-user-select':'none',
'-webkit-user-select':'none',
'-ms-user-select':'none',
'user-select':'none'})
@sousk
sousk / jquery_deferred_chains.js
Created March 17, 2011 10:06
combine multiple chains with jQuery.Deferred
$.when(
sushi_roll(),
dispatch()
).done(function() {
console.log('accepted:', arguments[0], arguments[1]);
});
var n = 0;
function dispatch() {
return $.Deferred(function(dispached) {
#!/usr/bin/env ruby
confbase = 'git-ssh-create'
init_command = 'git --bare init'
server = `git config --global #{confbase}.server`.chomp
if server.empty?
warn "Please set git config server."
warn " git config --global #{confbase}.server '[username@]yourserver.example.com'"
exit 1
@sousk
sousk / prove-runner (TM's command)
Created February 1, 2011 10:47
prove runner, TextMate's code snippet, make your test running on remote.
#!/usr/bin/env ruby
file = ENV['TM_FILEPATH']
if file =~ /\.t$/
local = ENV['LOCAL_PROJECT_ROOT']
remote = ENV['REMOTE_PROJECT_ROOT']
path = file.sub local, remote
else
local = ENV['TEST_LOCAL_DIR']