Skip to content

Instantly share code, notes, and snippets.

@yuuan
yuuan / git-rprompt.zsh
Last active February 24, 2016 14:59 — forked from uasi/gist:214109
Non zsh/pcre version.
#
# Show branch name in Zsh's right prompt
#
autoload -Uz VCS_INFO_get_data_git; VCS_INFO_get_data_git 2> /dev/null
setopt prompt_subst
function rprompt-git-current-branch {
local name st color gitdir action
@yuuan
yuuan / git-rprompt.zsh
Last active October 8, 2015 03:58 — forked from uasi/gist:214109
zsh/pcre version.
#
# Show branch name in Zsh's right prompt
#
autoload -Uz VCS_INFO_get_data_git; VCS_INFO_get_data_git 2> /dev/null
setopt prompt_subst
setopt re_match_pcre
function rprompt-git-current-branch {
@yuuan
yuuan / Wikipedia.citePopup.user.js
Created November 9, 2012 16:40
Add pop-up on reference to footnote
// ==UserScript==
// -*- mode:JScript; Encoding:utf8n -*-
// @name Wikipedia.citePopup
// @namespace http://d.hatena.ne.jp/p-arai/
// @description Add pop-up on reference to footnote
// @include http://ja.wikipedia.org/wiki/*
// @grant none
//
// @author p-arai, yuuAn
// @version 2012.11.10
@yuuan
yuuan / booklive.xml
Last active December 15, 2015 16:09
BookLive! Search for Firefox
<SearchPlugin xmlns="http://www.mozilla.org/2006/browser/search/" xmlns:os="http://a9.com/-/spec/opensearch/1.1/">
<os:ShortName>BookLive!</os:ShortName>
<os:Description>BookLive! で電子書籍を検索</os:Description>
<os:InputEncoding>UTF-8</os:InputEncoding>
<os:Image width="16" height="16">data:image/x-icon;base64,AAABAAEAEBAAAAEAIABoBAAAFgAAACgAAAAQAAAAIAAAAAEAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABUVFRUVFRU71FRUaU/Pz8EAFn+nABX9/gAWPxZVVVVGFVVVcxSUlLoUlJSKAAAAAAAAAAAAAAAAAAAAAAAAAAAVFRU5FNTU/9VVVX/P1V+wQBa//8AV/X/AFr//zJXm8xVVVX/UlJS/1RUVOdVVVU8AAAAAAAAAAAAAAAAUlJSKFVVVf9SUlL/VVVV/y9Xov8AWv//AFf2/wBa//9AVn//VFRU/1NTU/9VVVX/VFRU81VVVTwAAAAAAAAAAFRUVGxVVVX/UlJS/1VVVf8YWc//AFn8/wBY+f8DWvr/U1Va/1JSUv9VVVX/VVVV/1VVVf9VVVX7VFRUVAAAAABUVFS0VFRU/1NTU/9SVVr/A1r6/wBX9v8AWv//GFnP/1VVVf9SUlL/VVVV/1VVVf9VVVX/VVVV/1VVVfs/Pz8EVFRU81JSUv9VVVX/QFaA/wBa//8AV/f/AFr//y9Xov9VVVX/UlJS/1VVVf9VVVX/VVVV/1VVVf9VVVXUVVVVPFVVVf9SUlL/VVVV/yhYsP8AWv//AFf2/
@yuuan
yuuan / nicovideo.xml
Created August 17, 2013 15:37
niconico Search for Firefox
<SearchPlugin xmlns="http://www.mozilla.org/2006/browser/search/" xmlns:os="http://a9.com/-/spec/opensearch/1.1/">
<os:ShortName>ニコニコ動画</os:ShortName>
<os:Description>ニコニコ動画で動画を検索</os:Description>
<os:InputEncoding>UTF-8</os:InputEncoding>
<os:Image width="16" height="16">data:image/x-icon;base64,AAABAAEAEBAAAAEAIABoBAAAFgAAACgAAAAQAAAAIAAAAAEAIAAAAAAAAAAAABMLAAATCwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA0NDT/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADQ0NP8AAAAAAAAAAAAAAAA0NDT/NDQ0/zQ0NP80NDT/NDQ0/zQ0NP80NDT/NDQ0/zQ0NP80NDT/NDQ0/zQ0NP80NDT/NDQ0/wAAAAAAAAAANDQ0/////////////////////////////////////////////////////////////////zQ0NP8AAAAAAAAAADQ0NP//////////////////////NDQ0/zQ0NP80NDT/NDQ0//////////////////////80NDT/AAAAAAAAAAA0NDT///////////////////////////80NDT/NDQ0////////////////////////////NDQ0/wAAAAAAAAAANDQ0/////////////////////////////////////////////////////////////////zQ0NP8AAAAAAAAAADQ0NP////////////////////////////////////
@yuuan
yuuan / alc.xml
Last active December 21, 2015 05:29
SPACE ALC Search for Firefox
<SearchPlugin xmlns="http://www.mozilla.org/2006/browser/search/" xmlns:os="http://a9.com/-/spec/opensearch/1.1/">
<os:ShortName>アルク</os:ShortName>
<os:Description>スペースアルクで単語を調べる</os:Description>
<os:InputEncoding>UTF-8</os:InputEncoding>
<os:Image width="16" height="16">data:image/x-icon;base64,AAABAAEAEBAAAAEAIABoBAAAFgAAACgAAAAQAAAAIAAAAAEAIAAAAAAAAAAAABMLAAATCwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFRgjIBUYI2AVGCOAFRgjgBUYI2AVGCMwAAAAAAAAAAAAAAAAAAAAAAAAAAD///8AAAAAAAAAAAAVGCMwFRgjr0FDTP+KjJH/tre6/8XFyP+Zmp//e32D/ykrNb8VGCMgAAAAAAAAAAAAAAAA////AAAAAAAVGCNAMjU//7a3uv/////////////////////////////////w8fH/c3R77xUYI1AAAAAAAAAAAP///wAAAAAAFRgj3+Li5P////////////////////////////////////////////////+Zmp//FRgjUAAAAAD///8AAAAAABUYI4BTVl7v4uLk/////////////////////////////////////////////////3l7gd8AAAAA////AAAAAAAAAAAAFRgjEBUYI4+Zmp/////////////////////////////////////////////Fxcj/FRgjYP///wAVGCMgAAAAAAAAAAAAAAAAFRgjQEdKUt/i4uT//////////////////////////////////////yotN6////8AMjU//1BSWv9QUlr/U1Ze71BSWr8VGCO/JCYx/7a3uv/////
@yuuan
yuuan / autopagerize.css
Last active December 26, 2015 15:09
Stylishを使ってAutoPagerizeのページ番号を見やすくする。
@namespace url(http://www.w3.org/1999/xhtml);
.autopagerize_page_info {
line-height: 150%;
font-size: 13px !important;
font-weight: normal;
font-family: "Eras Medium ITC" !important;
}
.autopagerize_page_info a {
@yuuan
yuuan / doda.css
Created October 26, 2013 15:53
StylishでDODAの求人票を少しでも見やすく
@namespace url(http://www.w3.org/1999/xhtml);
@-moz-document domain("doda.jp") {
* {
font-family: 'A-OTF 新ゴ Pro 標準' !important;
}
}
@-moz-document url-prefix("https://doda.jp/Front/ReferredJob/View/ReferredJobDetail.aspx") {
body *, .ptext {
@yuuan
yuuan / dqnplus-font.css
Created October 27, 2013 04:29
Stylishを使って痛いニュースのフォントをKGCG-AAにする
@namespace url(http://www.w3.org/1999/xhtml);
/* blog.livedoor.jp/dqnplus */
@-moz-document url-prefix("http://blog.livedoor.jp/dqnplus/") {
@font-face {
font-family: "MS Pゴシック";
font-weight: normal;
src: local("KGCG-AA");
}
@font-face {
@yuuan
yuuan / git-rprompt.zsh
Last active December 26, 2015 16:09
Show branch name only version.
#
# Show branch name in Zsh's right prompt
#
function rprompt-git-current-branch {
local name
if [[ -n `echo "$PWD" 2> /dev/null | grep '/\.git(/.*)?$'` ]]; then
return
else
name=`git rev-parse --abbrev-ref=loose HEAD 2> /dev/null`