Skip to content

Instantly share code, notes, and snippets.

View masaakif's full-sized avatar

fujiwara-masaaki masaakif

View GitHub Profile
@masaakif
masaakif / flattentxt.rb
Created April 28, 2014 06:58
サブディレクトリ以下の全ての*.txtをWorking Directoryに移動する。その際にディレクトリ名もつける
Dir.glob("**/*.txt") do |f|
origname = f
newname = File.basename(f)
dirn = File.dirname(f)
dirn = dirn.gsub!("/","_")
unless dirn.nil?
newname = dirn + newname
end
puts "#{origname} -> #{newname}"
File.rename(origname, newname)
@masaakif
masaakif / libron@httplibronnet.user.js
Last active August 29, 2015 14:02
Liberon 3.0.5.s
// ==UserScript==
// @name Libron_1
// @namespace http://libron.net
// @description Amazon のページから最寄りの図書館の蔵書を検索
// @author Junya Ishihara(http://champierre.com)
// @include http://www.amazon.*
// @exclude http://www.amazon.co.jp/s/*
// ///exclude http://www.amazon.co.jp/gp/*
// @exclude http://www.amazon.co.jp/ref=gno_logo
// @license MIT License(http://en.wikipedia.org/wiki/MIT_License)
@masaakif
masaakif / libron2@httplibronnet.user.js
Last active August 29, 2015 14:02
Libron 3.0.5.s 2
// ==UserScript==
// @name Libron_2
// @namespace http://libron.net
// @description Amazon のページから最寄りの図書館の蔵書を検索
// @author Junya Ishihara(http://champierre.com)
// @include http://www.amazon.*
// @exclude http://www.amazon.co.jp/s/*
// ///exclude http://www.amazon.co.jp/gp/*
// @exclude http://www.amazon.co.jp/ref=gno_logo
// @license MIT License(http://en.wikipedia.org/wiki/MIT_License)
@masaakif
masaakif / libron3@httplibronnet.user.js
Last active August 29, 2015 14:02
libron 3.0.5.s 3
// ==UserScript==
// @name Libron_3
// @namespace http://libron.net
// @description Amazon のページから最寄りの図書館の蔵書を検索
// @author Junya Ishihara(http://champierre.com)
// @include http://www.amazon.*
// @exclude http://www.amazon.co.jp/s/*
// //exclude http://www.amazon.co.jp/gp/*
// @exclude http://www.amazon.co.jp/ref=gno_logo
// @license MIT License(http://en.wikipedia.org/wiki/MIT_License)
@masaakif
masaakif / jira_tweaks.user.js
Last active August 29, 2015 14:02
Add Arrow, Jira description, Open in new page
// ==UserScript==
// @name Jira Tweaks
// @namespace https://gist.github.com/masaakif/18a5bb2baa00c9c38a8b
// @description Jira Tweaks (includes Add Arrow and Open in New Page)
// @include http://sydlinux3/*
// @include http://jira/*
// @include http://sydln203/*
// ==/UserScript==
//
@masaakif
masaakif / Suginami_Library_New_Tweaks.user.js
Last active August 29, 2015 14:04
Suginami_Library_New_Tweaks.user.js
// ==UserScript==
// @id d88dd39a6bd9f76517c0
// @name Suginami_Library_New_Tweaks.user.js
// @version 1.0
// @namespace
// @author
// @description
// @include https://www.library.city.suginami.tokyo.jp/licsxp-opac/WOpacTifTilDetailYoyCartDispAction.do
// @run-at document-end
// ==/UserScript==
@masaakif
masaakif / jira_setInitialValue.user.js
Created April 10, 2015 00:30
JIRAのフィールド初期値設定
// ==UserScript==
// @id jira-a1e859d8-9b47-4c42-9c76-8ac4fc0a8157@scriptish
// @name JIRA_SetInitialValue
// @version 1.0
// @namespace
// @author Masaaki Fujiwara
// @description
// @include http://jira/secure/CreateIssue.jspa
// @run-at document-end
// ==/UserScript==
//Gorua
CmdUtils.CreateCommand({
name: "gorua",
takes: {"Gorua": noun_arb_text},
preview: function(pblock) {
pblock
pblock.innerHTML = "<small>d:削除<br>g:うおっ、なんかすげえ所に迷い込んじまったぞ、ゴルァ!<br>ns:なんだってー小<br>nb:なんだってー大</small>"
},
execute: function(arg) {
doc = CmdUtils.getDocumentInsecure();
@masaakif
masaakif / amazon_chuo_ward_library.user.js
Created December 16, 2008 06:45
Amazon Chuo Ward Library Linky
// ==UserScript==
// @name Amazon Chuo Ward Library Linky
// @namespace http://gist.github.com/36358
// @description Chuo Ward Library Lookup from Amazon book listings.
// @include http://*.amazon.*
// ==/UserScript==
// Version 20090105
var DEBUG=true;