Skip to content

Instantly share code, notes, and snippets.

View mohemohe's full-sized avatar
🍣
さーもん

mohemohe mohemohe

🍣
さーもん
View GitHub Profile
@mohemohe
mohemohe / watch-karabiner.1s.sh
Created January 25, 2023 06:15
watch-karabiner.1s.sh
#!/bin/bash
current="$(lsappinfo info -only name "$(lsappinfo front)" | cut -d'=' -f2)"
case "$current" in
'"Parsec"' | '"Parallels Desktop"' ) profile="PC" ;;
* ) profile="Default" ;;
esac
if [[ ! -e /tmp/watch-karabiner ]]; then
touch /tmp/watch-karabiner
@mohemohe
mohemohe / install_docker-compose.sh
Last active October 30, 2022 06:22
install/update docker compose v2
#!/bin/bash -x
if [[ "${COMPOSE_VERSION}" == "" ]]; then
echo "must be set env 'COMPOSE_VERSION'"
exit 1
fi
OS="$(uname -s | awk '{print tolower($0)}')"
ARCH="$(uname -m)"
@mohemohe
mohemohe / youtube-subtitle.js
Last active August 6, 2021 15:09
youtube-subtitle.js
(async () => {
const wait = (ms) => new Promise(resolve => setTimeout(resolve, ms));
const subtitleButton = document.querySelector('.ytp-subtitles-button');
if (!subtitleButton) {
return;
}
const subtitleButtonState = subtitleButton.getAttribute('aria-pressed') === 'true';
subtitleButton.click();
if (subtitleButtonState) {
@mohemohe
mohemohe / LICENSE
Created June 2, 2021 03:10
guregu/dynamo migrate script
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2020 mohemohe <[email protected]>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
// This file was initially generated by Windows Terminal 1.0.1401.0
// It should still be usable in newer versions, but newer versions might have additional
// settings, help text, or changes that you will not see unless you clear this file
// and let us generate a new one for you.
// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
{
"$schema": "https://aka.ms/terminal-profiles-schema",
@mohemohe
mohemohe / score20200823005406.txt
Created August 22, 2020 17:28
MacBook Pro 13 2020 FF14ベンチ
ファイナルファンタジーXIV: 漆黒のヴィランズ ベンチマーク
計測日時: 2020/8/23 0:54:06
SCORE: 4425
平均フレームレート: 30.50928
最低フレームレート: 6
評価: 快適
-快適な動作が見込めます。グラフィック設定をより高品質にしても快適に動作すると思われます。
ローディングタイム:
シーン#1 3.143sec
シーン#2 6.465sec
@mohemohe
mohemohe / startx
Created June 16, 2020 08:26
WSL2でxfceを使う
#!/bin/bash
cd "${HOME}"
if [ ! -z "$(pidof xfce4-session)" ]; then
exit 1
fi
export DISPLAY="$(cat /etc/resolv.conf | grep nameserver | awk '{print $2; exit;}'):0.0";
export LANG=ja_JP.UTF-8
;;
;; Emulate_Scrolling_Middle_Button.ahk
;; Author: Erik Elmore <[email protected]>
;; Version: 1.1 (Aug 16, 2005)
;;
;; Enables you to use any key with cursor movement
;; to emulate a scrolling middle button. While
;; the TriggerKey is held down, you may move the
;; mouse cursor up and down to send scroll wheel
;; events. If the cursor does not move by the
Domain
shopingmall.srl Delete
104.27.172.201 (from shopingmall.srl) Delete
104.27.173.201 (from shopingmall.srl) Delete
2606:4700:3033::681b:adc9 (from shopingmall.srl) Delete
2606:4700:3033::681b:acc9 (from shopingmall.srl) Delete
fashion-buy.in.net Delete
104.18.58.207 (from fashion-buy.in.net) Delete
104.18.59.207 (from fashion-buy.in.net) Delete
2606:4700:3031::6812:3bcf (from fashion-buy.in.net) Delete
@mohemohe
mohemohe / say.sh
Last active February 21, 2022 06:25
voiceroid_daemon say
#!/bin/bash
BASE_URL=http://172.16.34.56:8080
#=====================================
function _exit() {
exit 1
}