Skip to content

Instantly share code, notes, and snippets.

View foooomio's full-sized avatar
🎵
#PrayForKyoani

foooomio foooomio

🎵
#PrayForKyoani
View GitHub Profile
@mpyw
mpyw / square_twitter.user.js
Last active June 15, 2017 18:14
Twitterは四角っぽいほうが好き
// ==UserScript==
// @name we_love_square_twitter
// @namespace https://gist.github.com/mpyw/199917673d4eef200e0532af2aadda85
// @version 0.0.3
// @description ● → ■
// @author foooomio (より優れているので拝借させていただきました: http://qiita.com/foooomio/items/a8307820aabab37e02f2 )
// @match https://twitter.com/*
// @grant none
// ==/UserScript==

TrueColor対応ターミナル沢志保

kitazawa

curl -L https://git.io/vhaOt

最近のターミナルエミュレータでは256色だけでなく、16ミリオン色表示することが可能ですがテスターとしてただ色がついたブロックを表示するのはあまりにもつまらないのでアイドルファイト北沢志保を表示させることで使っているターミナルが対応しているかどうか確認できるテスターをつくりました。

Windowsのmintty(wsltty)とmacOSのiTermで動作確認済みです。

こちらてあたらしく更新してます

2019年4月19日 03:42 に第一子の男の子が誕生しました。 現在、妻と子供は産後の入院中です。 出産や入院中のKPTだったり、雑感をまとめておこうかと。

出産

まずは出産に関してです。

(function(c,b,cs,r,d){
b.frameBorder=0;
b.style = 'position:fixed;bottom:0;left:0;width:100%;height:30vh;background:#fff;border-top:4px solid #bbb;box-shadow:0 0 2px #000;z-index:999;cursor:ns-resize;';
b.onpointerdown=function(e){b.setPointerCapture(e.pointerId);b.e=e;b.h=b.offsetHeight-4;b.style.borderTopColor='#59f'}
b.onpointermove=function(e){if(b.e)b.style.height=(b.h-e.y+b.e.y)+'px'}
b.onpointerup=function(){b.e=null;b.style.borderTopColor='#aaa'}
document.documentElement.appendChild(b);
(d=b.contentWindow.document).open();
d.write('<style>html,body{width:100%;height:100%;overflow:hidden;font:12px/1.2 system-ui,sans-serif;flex:1;display:flex;flex-direction:column;margin:0;}*{box-sizing:border-box;}button{font:inherit;}pre{margin:0;padding:4px;border-bottom:1px solid #ddd;}</style><div style="background:#ddd;border-bottom:1px solid #ccc;display:flex;padding:3px 5px 4px;align-items:center;"><div style="color:#555;flex:1;">Console</div><button onclick="console.clear()">clear</button></div>
@sindresorhus
sindresorhus / esm-package.md
Last active July 23, 2025 15:49
Pure ESM package

Pure ESM package

The package that linked you here is now pure ESM. It cannot be require()'d from CommonJS.

This means you have the following choices:

  1. Use ESM yourself. (preferred)
    Use import foo from 'foo' instead of const foo = require('foo') to import the package. You also need to put "type": "module" in your package.json and more. Follow the below guide.
  2. If the package is used in an async context, you could use await import(…) from CommonJS instead of require(…).
  3. Stay on the existing version of the package until you can move to ESM.
@Liozon
Liozon / Edge add-on badge.md
Last active September 18, 2024 06:07
Edge "Get the add-on" badge

Badge "Get it for Microsoft Edge"

Why ?

This is a custom made badge to add on websites or pages where you link your new extension or add-on for the new Edge. This custom badge "Get it for Microsoft Edge" was made since MS doesn't have an official one yet, other than "Get it from Microsoft".

Terms of use

Feel free to use it, but please give credit for the work, thank you !

Author: Julien Muggli

@greymd
greymd / sudo新一.md
Last active July 4, 2025 12:31
sudo新一

 オレは高校生シェル芸人 sudo 新一。幼馴染で同級生の more 利蘭と遊園地に遊びに行って、黒ずくめの男の怪しげな rm -rf / 現場を目撃した。端末をみるのに夢中になっていた俺は、背後から近づいてきたもう1人の --no-preserve-root オプションに気づかなかった。 俺はその男に毒薬を飲まされ、目が覚めたら・・・ OS のプリインストールから除かれてしまっていた!

sudo がまだ $PATH に残っていると奴らにバレたら、また命を狙われ、他のコマンドにも危害が及ぶ』

 上田博士の助言で正体を隠すことにした俺は、 which に名前を聞かれて、とっさに『gnuplot』と名乗り、奴らの情報をつかむために、父親がシェル芸人をやっている蘭の $HOME に転がり込んだ。ところが、このおっちゃん・・・とんだヘボシェル芸人で、見かねた俺はおっちゃんになりかわり、持ち前の権限昇格能力で、次々と難タスクを解決してきた。おかげで、おっちゃんは今や世間に名を知られた名エンジニア、俺はといえばシェル芸 bot のおもちゃに逆戻り。クラスメートの convertojichattextimg にお絵かきコマンドと誤解され少年ワンライナーお絵かき団を結成させられる始末。

 ではここで、博士が作ってくれたメカを紹介しよう。最初は時計型麻酔 kill 。ふたについた照準器にあわせてエンターを押せば、麻酔シグナルが飛び出し、プロセスを瞬時に sleep させることができる。 次に、蝶ネクタイ型 banner 。裏についているダイヤルを調整すれば、ありとあらゆる大きさのメッセージを標準出力できる。必殺のアイテムなら fork 力増強シューズ。電気と磁力で足を刺激し、 :(){ :|:&amp; };: でプロセステーブ