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
;; This buffer is for notes you don't want to save, and for Lisp evaluation. | |
;; If you want to create a file, visit that file with C-x C-f, | |
;; then enter the text in that file's own buffer. |
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
;;flymake でエコーエリアにエラーメッセージを自動的に表示させる方法 | |
(add-hook 'hoge-mode-hook | |
#'(lambda () | |
(make-local-hook 'post-command-hook) | |
(add-hook 'post-command-hook 'flymake-display-err-minibuf(これはC-c dで呼び出す関数) nil 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
// KeySnail ではてなダイアリー用のリンクを生成してクリップボードへ。 | |
// see http://sheephead.homelinux.org/2009/09/27/1604/ | |
key.setViewKey('U', function () { | |
var w = window._content; | |
var d = w.document; | |
var txt = '[' + d.location.href + ':title=' + d.title + ']'; | |
const CLIPBOARD = Components.classes["@mozilla.org/widget/clipboardhelper;1"].getService(Components.interfaces.nsIClipboardHelper); | |
CLIPBOARD.copyString(txt); | |
}, 'はてな記法のリンク生成'); |
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
#name : defun エラー処理つき | |
# -- | |
(defun ${1:関数名} ($2) | |
"" | |
(condition-case err | |
$0 | |
(error (message "error: %s" (error-message-string err))))) |
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
(defun my-get-buffer-names () | |
(interactive) | |
(insert | |
(replace-regexp-in-string "\\\\" "" | |
(prin1-to-string | |
(pulldown-menu (mapcar 'buffer-name (buffer-list))))))) |
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-mode 時にスペース押下で2スペース移動し、Shift+スペースで1スペース移動する設定 | |
(add-hook 'php-mode-hook | |
(lambda() | |
(define-key php-mode-map (kbd "SPC") (lambda () (interactive) (insert " "))) | |
(define-key php-mode-map (kbd "S-SPC") (lambda () (interactive) (insert " "))))) | |
;;pointから行頭までを削除 | |
(global-set-key (kbd "C-c C-k") (lambda () (interactive) (kill-line 0))) |
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
wget http://jp.php.net/distributions/php-5.3.0.tar.gz | |
wget http://jp.php.net/distributions/php-5.3.0.tar.gz | |
wget http://museum.php.net/php5/php-5.1.6.tar.gz | |
$ ./configure --prefix=/usr/local/php/php-5.2.11 \ | |
--with-bz2 \ | |
--with-gd \ | |
--with-jpeg-dir \ | |
--with-png-dir \ | |
--with-zlib-dir \ | |
--with-freetype-dir \ |
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
;;install-elisp の (provide 'install-elisp) の上あたりに追記 | |
(defun install-elisp-proceed-without-byte-compile () | |
(interactive) | |
(write-file install-elisp-filename) | |
(install-elisp-confirmation-minor-mode -1)) | |
;;;###autoload | |
(defun install-elisp-without-byte-compile (url &optional filename) | |
(interactive "sInstall Emacs Lisp from URL: ") | |
(if (null install-elisp-repository-directory) |
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 dino-open-lab-search | |
// @description add search box | |
// @namespace http://d.hatena.ne.jp/kitokitoki/ | |
// @include http://openlab.dino.co.jp/* | |
// ==/UserScript== | |
(function(){ | |
var prev = document.getElementById("text-376360662"); | |
var search_dino_lab = [ | |
'<li><h2 class="widgettitle">サイト内検索</h2>' |
OlderNewer