This file contains hidden or 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
(defun kn-heisei () | |
(interactive) | |
(message "平成%d年" (- (nth 5 (decode-time)) 1988))) | |
(defalias 'heisei 'kn-heisei) |
This file contains hidden or 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
#!/bin/bash | |
cd /var/tmp | |
curl -L https://download-chromium.appspot.com/dl/Mac >chrome-mac.zip | |
unzip chrome-mac.zip | |
rm chrome-mac.zip | |
rm -rf ~/Applications/Chromium.app | |
mv chrome-mac/Chromium.app ~/Applications/ | |
rmdir chrome-mac |
This file contains hidden or 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
;; 普通の1行電卓のM-x calculatorより逆ポー電卓のM-x calcのほうがタイプ数短いのずっと納得行ってない | |
;; calculatorをclcに逃す | |
;; clはCommon Lispと被っておかしくなるのが不安だし、M-x calは15年以上calendarに割り当てていて染み付いているので | |
(defalias 'cal 'calendar) | |
(defalias 'clc 'calculator) |
This file contains hidden or 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
C:\path\to\elevate.exe notepad C:\Windows\System32\drivers\etc\hosts |
This file contains hidden or 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
exec 42<>/dev/tcp/127.0.0.1/smtp | |
(echo 'HELO localhost' \ | |
;echo 'mail from:foo@example.com' \ | |
;echo 'rcpt to:bar@example.com' \ | |
;echo 'data' \ | |
;echo 'From:foo@example.com' \ | |
;echo 'To:bar@example.com' \ | |
;echo 'Subject:qux' \ | |
;echo '' \ | |
;echo 'quux' \ |
This file contains hidden or 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
function di() { | |
diff -uN --ignore-all-space $@ | |
} |
This file contains hidden or 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/getmail 2010-01-05 00:52:45.000000000 +0900 | |
+++ getmail_wait1sec 2013-07-11 17:12:01.000000000 +0900 | |
@@ -185,6 +185,15 @@ | |
break | |
if msg is not None: | |
+ | |
+ #time.sleep(2) #knagano | |
+ #knagano wait at least 1sec | |
+ time_before = time.time() |
This file contains hidden or 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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE html PUBLIC "-//i-mode group (ja)//DTD XHTML i-XHTML(Locale/Ver.=ja/1.1) 1.0//EN" "i-xhtml_4ja_10.dtd"> | |
<html xmlns="http://www.w3.org/1999/xhtml"> | |
<head> | |
<noscript><meta http-equiv="refresh" content="1;URL=sessionerror.php?errorcode=90002" /></noscript> | |
<style>:root{background: #000000;}</style> | |
<script type="text/javascript" src="http://aimg-pf.gree.net/js/app/touch.js?201304051400\"></script> | |
<script type="text/javascript"> | |
<!-- | |
var is_pc = 0; |
This file contains hidden or 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
(defun ack () | |
(interactive) | |
(let ((buf (get-buffer "*grep*"))) | |
(and buf (kill-buffer buf))) | |
(let ((save grep-find-command)) | |
(grep-apply-setting 'grep-find-command "ack --nocolor --nogroup ") | |
(unwind-protect | |
(call-interactively 'grep-find) | |
(grep-apply-setting 'grep-find-command save)))) |
This file contains hidden or 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
#!/bin/bash | |
function tomcatchk() { | |
tmp=$(ps auxww |grep tomcat |grep java |wc -l) | |
if [ $tmp = '0' ]; then | |
return 1 #false | |
fi | |
return 0 #true | |
} |
NewerOlder