Skip to content

Instantly share code, notes, and snippets.

View ttdoda's full-sized avatar

IWAMOTO Kouichi ttdoda

  • Kanagawa, Japan
View GitHub Profile
@ttdoda
ttdoda / gist:a17cd034ef56c321e427
Created May 17, 2015 13:30
MyFleetGirls error
sue@nagato% sh -x MyFleetGirls.sh
+ dirname MyFleetGirls.sh
+ cd .
+ java -jar update.jar
myfleetgirls.keystoreに変更はありません
LICENSEに変更はありません
application.conf.sampleに変更はありません
MyFleetGirls.jarは存在しません。ダウンロードします。
おやっ、IOExceptionです!
java.io.EOFException
@ttdoda
ttdoda / sayaka.php.diff
Created June 11, 2015 08:46
sixel画像表示後のカーソル位置非互換の吸収
diff --git a/sayaka.php b/sayaka.php
index cdcf37b..900ed7e 100644
--- a/sayaka.php
+++ b/sayaka.php
@@ -426,9 +426,10 @@ function showstatus($status, $s)
// 今のところローカルアカウントはない
$profile_image_url = $s->user->profile_image_url;
+ print "\n\n\n".CSI."3A".ESC."7";
show_icon(unescape($s->user->screen_name), $profile_image_url);
@ttdoda
ttdoda / gist:dbe31e47ac75ba488f59
Created June 23, 2015 07:02
syscons ws_{x,y}pixel対応
Index: sys/dev/syscons/scvidctl.c
===================================================================
--- sys/dev/syscons/scvidctl.c (revision 284698)
+++ sys/dev/syscons/scvidctl.c (working copy)
@@ -237,6 +237,8 @@
return 0;
wsz.ws_col = scp->xsize;
wsz.ws_row = scp->ysize;
+ wsz.ws_xpixel = scp->xpixel;
+ wsz.ws_ypixel = scp->ypixel;
@ttdoda
ttdoda / w3m-sgr-style.diff
Last active August 29, 2015 14:26 — forked from saitoha/w3m-sgr-style.diff
SGR 1006 mouse reporting for w3m
Index: keybind.c
===================================================================
RCS file: /cvsroot/w3m/w3m/keybind.c,v
retrieving revision 1.10
diff -u -r1.10 keybind.c
--- keybind.c 29 May 2006 12:17:25 -0000 1.10
+++ keybind.c 14 Jul 2012 21:20:27 -0000
@@ -91,7 +91,7 @@
/* 0 1 2 3 4 5 6 7 */
nulcmd, nulcmd, nulcmd, nulcmd, nulcmd, nulcmd, nulcmd, nulcmd,
diff --git a/main.c b/main.c
index 9cac333..7c5780c 100644
--- a/main.c
+++ b/main.c
@@ -5561,6 +5561,7 @@ DEFUN(sgrmouse, SGRMOUSE, "SGR 1006 mouse operation")
else
return;
} while (1);
+ if (x>0) x--;
@ttdoda
ttdoda / w3m-sgr-style-menu.diff
Last active August 29, 2015 14:26
SGR 1006 mouse reporting for w3m's menu
--- menu.c.orig 2011-01-04 18:22:23.000000000 +0900
+++ menu.c 2015-08-05 17:37:19.035511000 +0900
@@ -57,6 +57,7 @@
static int mClose(char c);
static int mSusp(char c);
static int mMouse(char c);
+static int mSgrMouse(char c);
static int mSrchF(char c);
static int mSrchB(char c);
static int mSrchN(char c);
@ttdoda
ttdoda / moduli-bits.lis
Created August 21, 2015 11:45
OpenSSH portable moduli bits
ver 1024 1536 2048 3072 3192 4096 6144 7680 8192
openssh-2.9.9p1 38 31 36 - 36 14 - - -
openssh-2.9.9p2 38 31 36 - 36 14 - - -
openssh-3.0p1 38 31 36 - 36 14 - - -
openssh-3.0.1p1 38 31 36 - 36 14 - - -
openssh-3.0.2p1 38 31 36 - 36 14 - - -
openssh-3.1p1 38 31 36 - 36 14 - - -
openssh-3.2.2p1 38 31 36 - 36 14 - - -
openssh-3.2.3p1 38 31 36 - 36 14 - - -
openssh-3.3p1 38 31 36 - 36 14 - - -
@ttdoda
ttdoda / TERATERM-Solarized.INI
Created November 1, 2012 14:23
Tera Term Solarized color setting
ANSIColor=0,7,54,66, 1,203,75,22, 2,88,110,117, 3,101,123,131, 4,131,148,150, 5,108,113,196, 6,147,161,161, 7,253,246,227, 8,0,43,54, ,220,50,47, 10,133,153,0, 11,181,137,0, 12,38,139,210, 13,211,54,130, 14,42,161,152, 15,238,232,213
; Solarized Dark
VTColor=131,148,150,0,43,54
VTBoldColor=147,161,161,7,54,66
VTBlinkColor=133,153,0,0,43,54
;VTReverseColor=0,43,54,131,148,150
VTReverseColor=101,123,131,253,246,227
URLColor=181,137,0,0,43,54
for b2 in {0..5}; do for r in {0..85}; do for b1 in {0..5}; do for g in {0..127}; do echo -ne "\e[48:2:$((r*3)):$((g*2)):$((b1*7 + b2*42))m "; done; echo -ne "\e[m"; done; echo; done; done
@ttdoda
ttdoda / gist:fc7fa7ea1b774f6597f8
Created November 24, 2015 13:50
Graf Zeppelin ドロップ確率
% ruby -e '10.step(200,10) do |i| puts "%3d: %f\n"%[i, (1 - (1-0.025) **i) * 100] end'
10: 22.367038
20: 39.731232
30: 53.211570
40: 63.676756
50: 71.801190
60: 78.108428
70: 83.004924
80: 86.806219
90: 89.757277