Skip to content

Instantly share code, notes, and snippets.

@mareku
mareku / video_keyboard_control.user.js
Last active February 15, 2023 00:53
html5 video keyboard control
// ==UserScript==
// @name video keyboard control
// @namespace https://github.com/mareku
// @version 1.6
// @description html5 video keyboard control
// play & Stop = K
// Back = J
// Advance = L
// Mute = M
// Speed Down = Z
// object array
var ary = [
['aaa', 1],
['bbb', 2],
['ccc', 3],
['ddd', 4],
['eee', 5],
['ddd', 4],
['bbb', 2],
['aaa', 1],
@mareku
mareku / youtube_speed_key.user.js
Last active May 8, 2018 06:23
change reproducing speed using key
// ==UserScript==
// @name youtube speed key
// @namespace http://tampermonkey.net/
// @version 0.2
// @match https://www.youtube.com/watch?*
// ==/UserScript==
(function() {
var down_key = 90, // z
riset_key= 88, // x
@mareku
mareku / youtube_channel_rss
Created March 14, 2018 00:33
youtube user and channel rss Bookmarklet
javascript:void(function(t){prompt('channel RSS URL','https://www.youtube.com/feeds/videos.xml?channel_id='+t[1])})(location.href.match(/https?:\/\/www.youtube.com\/channel\/([^/?]+)/));
@mareku
mareku / nicovideo_user_rss
Created March 14, 2018 00:27
nicovideo user RSS Bookmarklet
javascript:void(function(t){prompt('','http://www.nicovideo.jp/user/'+t[1]+'/video?rss=2.0')})(location.href.match(/http:\/\/www.nicovideo.jp\/user\/([^/?]+)/));
@mareku
mareku / post_new_tab_tumblr.js
Last active March 9, 2018 00:00
Post_Tumblr ブックマークレット
javascript:var d=document,w=window,e=w.getSelection,k=d.getSelection,x=d.selection,s=(e?e():(k)?k():(x?x.createRange().text:0)),f='http://www.tumblr.com/share',l=d.location,e=encodeURIComponent,p='?v=3&u='+e(l.href) +'&t='+e(d.title) +'&s='+e(s),u=f+p;try{if(!/^(.*\.)?tumblr[^.]*%24/.test(l.host))throw(0);tstbklt();}catch(z){a =function(){if(!w.open(u,'_blank',))l.href=u;};if(/Firefox/.test(navigator.userAgent))setTimeout(a,0);else a();}void(0);
@mareku
mareku / GetDetailsOf.uws
Created January 10, 2016 11:10
GetDetailsOfでファイルのプロパティを取得 OSや環境で番号が変わるからこのuwsで確認する。
Option Explicit
Dim objShell
objShell = CreateOleObj("Shell.Application")
DIM s_dir = GET_CUR_DIR
DIM s_fileNmae = "GetDetailsOf.uws"
DIM o_folder = objShell.NameSpace(s_dir)
DIM o_item = o_folder.ParseName(s_fileNmae)
@mareku
mareku / GAS1
Created January 3, 2016 11:34
スプレッドシート関数使用例
■年間配当利回り %
=iferror(REGEXextract(REGEXreplace(index (importhtml(concatenate("https://www.google.com/finance?q=",$A3), "table", 2), 1, 2); "[()]"; "") ; "/([^/]*)"),"-")
■直近配当金額、配当利回り% を、2セルに分割して表示
=split(ImportXML(concatenate("http://finance.google.com/finance?q=",A3), "//td[@data-snapfield='latest_dividend-dividend_yield']/following-sibling::*"),"/")
■過去5年の増配平均/年  (5-yr Dividend CAGR)
=index ( importhtml("http://www.gurufocus.com/dividend/"&A3&"", "table", 4), 2, 3)
@mareku
mareku / A smart dashboard is_mine
Last active December 10, 2015 07:18
tumblr own Posts Invisible
div.post.is_mine {
-moz-opacity:0.5 !important;
opacity:0.5 !important;
max-height:3em !important;
overflow:hidden !important;
}
div.post.is_mine img {
display:none !important;
}
div.post.is_mine blockquote {
@mareku
mareku / 0_reuse_code.js
Last active August 29, 2015 14:13
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console