GitHubの自分のリポジトリ一覧を見ていて、全部のリポジトリの設定ページを開きたくなったときにやったこと。
Option + ⌘ + I
でとりあえずDOMを見る.repolist-name
とればいいっぽいOption + ⌘ + J
でとりあえずコンソールを開く
GoogleChrome-DevTools-Console
Array.prototype.slice.call(document.querySelectorAll('.repolist-name a')).forEach(function(elm){console.log(elm.href+'/settings');});
ちゃんと出力された。
- 出力された文字列をいい感じに選択してクリップボードにコピーする
- とりあえずVimに貼付ける
Vim-Scratch
https://github.com/sasaplus1/sasaplus1.github.io/settings VM479:2
https://github.com/sasaplus1/stylesheetselector.js/settings VM479:2
https://github.com/sasaplus1/dotfiles/settings VM479:2
https://github.com/sasaplus1/ltsv-web/settings VM479:2
https://github.com/sasaplus1/slide-first-time-node.js/settings VM479:2
https://github.com/sasaplus1/http-router/settings VM479:2
https://github.com/sasaplus1/ltsv.js/settings VM479:2
https://github.com/sasaplus1/base62.js/settings VM479:2
https://github.com/sasaplus1/rumia/settings VM479:2
https://github.com/sasaplus1/pfmclock/settings VM479:2
https://github.com/sasaplus1/mktemp/settings VM479:2
https://github.com/sasaplus1/pfmloop/settings VM479:2
https://github.com/sasaplus1/generator-prototyping/settings VM479:2
https://github.com/sasaplus1/generator-flowtime/settings VM479:2
https://github.com/sasaplus1/dtree/settings VM479:2
https://github.com/sasaplus1/ltsview/settings VM479:2
https://github.com/sasaplus1/deepcopy.js/settings VM479:2
https://github.com/sasaplus1/split-stream/settings VM479:2
いい感じにカーソルを移動しつつ、以下のようなことをする。
"+P
:%S/ .+$//
- eregex.vim使用
gg^vGI
+ "open "ggO
+ "#!/bin/bash"
Vim-Scratch
#!/bin/bash
open https://github.com/sasaplus1/sasaplus1.github.io/settings
open https://github.com/sasaplus1/stylesheetselector.js/settings
open https://github.com/sasaplus1/dotfiles/settings
open https://github.com/sasaplus1/ltsv-web/settings
open https://github.com/sasaplus1/slide-first-time-node.js/settings
open https://github.com/sasaplus1/http-router/settings
open https://github.com/sasaplus1/ltsv.js/settings
open https://github.com/sasaplus1/base62.js/settings
open https://github.com/sasaplus1/rumia/settings
open https://github.com/sasaplus1/pfmclock/settings
open https://github.com/sasaplus1/mktemp/settings
open https://github.com/sasaplus1/pfmloop/settings
open https://github.com/sasaplus1/generator-prototyping/settings
open https://github.com/sasaplus1/generator-flowtime/settings
open https://github.com/sasaplus1/dtree/settings
open https://github.com/sasaplus1/ltsview/settings
open https://github.com/sasaplus1/deepcopy.js/settings
open https://github.com/sasaplus1/split-stream/settings
\r
- vim-quickrun使用
Google Chromeにずばばばーっとタブが表示されました。WikiとかIssueのon/offしたかっただけです。