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
# 使い方) | |
# video_1.mp4, video_2.mp4, video_3.mp4,… を video.mp4 に連結したい時、 | |
# 冒頭のfilenameにファイル接頭辞videoを渡す。つまり、filename=videoとする。 | |
# ※FFMPEGを事前インストールしておく必要があります。 (macの場合は、$ brew install ffmpeg) | |
filename=ファイル名接頭辞;ffmpeg -f concat -safe 0 -i <(for f in ${filename}_*.mp4; do echo "file '$PWD/$f'"; done) -codec copy ${filename}.mp4 |
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
# pdf2svgをインストール | |
brew install pdf2svg | |
# なお、brewコマンドが見つからない(Homebrew未インストール)の場合は下記実行してインストールする。ref: https://brew.sh/index_ja | |
# /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)" | |
# pdfファイルをsvgファイルに変換 | |
# 例)input.pdfファイルをoutput.svgに変換出力する場合 | |
pdf2svg input.pdf output.svg |
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
"ref: https://rcmdnk.com/blog/2014/10/22/computer-firefox/ | |
"ref: https://fewlight.net/20151023/ | |
"Settings | |
let scrolltep = 200 | |
let fullpagescrollpercent = 100 | |
"set nohud | |
"set autohidecursor | |
"set noinsertmappings | |
set nosmoothscroll |
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
mkdir "%~dp0\%~n1" | |
ffmpeg -i "%1" -vcodec png -sameq "%~dp0\%~n1\%%d.png" |
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
#------------------------------------------------------------------------------ | |
# 履歴 | |
#------------------------------------------------------------------------------ | |
alias his="fc -l -f 0 | sort -r | peco" | |
setopt extended_history | |
function peco-select-history() { | |
local tac | |
if which tac > /dev/null; then | |
tac="tac | uniq" | |
else |
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
"==============================================================================" | |
" Hightlight matched URLs " | |
" usage(example): " | |
" :highlightUrls [regex] " | |
" :highlightUrls github|gitlab " | |
"==============================================================================" | |
js <<EOM | |
commands.addUserCommand( | |
["highlightUrls"], | |
"Highlight matched URLs", |
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
// ページ内のすべてのURLについて,正規表現`url_regex`にマッチするものを紫色で強調 | |
var url_regex = /hatena/; | |
var iterator = document.evaluate("//a", document, null, 5, null); | |
var highlighter = function(elm) { | |
elm.style = | |
"font-weight:900;" + | |
"color:white;" + | |
"background-color:purple;"; | |
}; | |
var node; |
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
# ref: 第8回 Perlによる大規模システム開発・設計のツボ(3):Perl Hackers Hub|gihyo.jp … 技術評論社 | |
# http://gihyo.jp/dev/serial/01/perl-hackers-hub/000803 | |
# コンポーネントの単一責務性の違反指数(SRP) | |
# SRP=R+U+((L/100)-5) | |
# R:修正リビジョンのユニーク数 | |
# U:修正ユーザのユニーク数 | |
# L:モジュールのライン数 | |
function get_SRP() { | |
local target_filepath=$1 |
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
#!/bin/bash | |
# constants | |
seed_number=1234 | |
# check args | |
if [ $# -ne 2 ]; then | |
echo "usage: $0 [before_revision_hash] [after_revision_hash]" | |
echo "e.g.: $0 212dfa0 0bc3dc7" | |
echo "e.g.: $0 0bc3dc7^ 0bc3dc7" |
NewerOlder