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
// ==UserScript== | |
// @name Bluesky - SSTP over HTTP で喋らせるボタンを生やすやつ | |
// @namespace https://github.com/nikolat/ | |
// @version 0.1 | |
// @contributor unarist https://gist.github.com/unarist/3134f59953569a4a8ea692185b94eaeb | |
// @author nikolat https://gist.github.com/nikolat/c945aa7dce03dd86a43c947a32fb83b9 | |
// @match https://tokimeki.blue/* | |
// @grant GM.xmlHttpRequest | |
// @homepage https://gist.github.com/nikolat/c945aa7dce03dd86a43c947a32fb83b9 | |
// @downloadURL https://gist.github.com/nikolat/c945aa7dce03dd86a43c947a32fb83b9/raw/4d488784ae5c9a38ab4957a21239b7668da46ed5/bluesky-sstp-over-http.user.js |
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
// http://d.hatena.ne.jp/fumokmm/20110822/1314013182 | |
// ローマ数字定義 | |
def romans = [ | |
I :1 , | |
IV:4 , V:5 , IX:9 , X:10 , | |
XL:40 , L:50 , XC:90 , C:100 , | |
CD:400, D:500, CM:900, M:1000 | |
] | |
// シンボル化能力を追加 |
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
// http://d.hatena.ne.jp/fumokmm/20110812/1313138407 | |
def dropStartsSame(String... args) { | |
if (args.any{!it}) return args | |
args*.substring( | |
args*.toList().transpose().with{ | |
def i=0; it.collect{[i++, it]} | |
}.with{ dup -> | |
dup.find{ it[1].unique().size() != 1 }.with { | |
it ? it[0] : dup.last()[0]+1 | |
} |
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
// http://d.hatena.ne.jp/fumokmm/20110815/1313405510 | |
def fizzBuzzN(nums, list) { | |
def toMap = { lst -> (0..<lst.size()/2).collectEntries{ lst[it*2..it*2+1] } } | |
toMap(list).collect{ k, v -> | |
v = nums.collect{ it % k == 0 ? v : '' } | |
}.transpose()*.join().eachWithIndex{ it, idx -> | |
println(it ? it : idx+nums.from) | |
} | |
} | |
fizzBuzzN(1..100, [3, 'Fizz', 5, 'Buzz', 7, 'Hoge']) |
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
def array = [] | |
def tmp = "" | |
array = ('0'..'9') + ('a'..'z') + ('A'..'Z') + '_' | |
(1..16).each { | |
tmp += array[Math.floor(Math.random() * array.size()) as int] | |
} | |
println tmp |
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
aaa |
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
// ==UserScript== | |
// @name replace star by profile icon | |
// @namespace http://www.hatena.ne.jp/Nikola/ | |
// @description replace star by profile icon (for Google Chrome8) | |
// @include http://*.hatena.ne.jp/* | |
// @version 1.0.0 | |
// ==/UserScript== | |
(function () { | |
var executeBrowserContext = function(funcOrString) { |
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
// ==UserScript== | |
// @name Hatena Haiku notify auto opener | |
// @namespace http://www.hatena.ne.jp/Nikola/ | |
// @description はてなハイク1.1の新着通知を自動で開きます。Google Chromeにも対応。 | |
// @include http://h1beta.hatena.ne.jp/* | |
// @include http://h1beta.hatena.com/* | |
// ==/UserScript== | |
(function () { |