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 | |
cd "$(dirname "$0")" || exit | |
progress() { | |
local message=$1 | |
local space | |
space=$(printf '%*s' $(( $(tput cols) - ${#message} )) ' ') | |
echo -ne "$message$space\r" | |
} |
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
@echo off | |
echo [INFO] SetDPI 100 | |
SetDPI.exe 1 100 | |
echo [INFO] Connect RDP | |
start C:\Windows\System32\mstsc.exe "C:\Users\Tomachi\ICHIGO-MULTI-REMOTE.rdp" | |
timeout /T 10 /NOBREAK | |
:check |
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 | |
if [[ $# -ne 2 ]]; then | |
echo "Error: 2つの引数が必要です。1つ目にscreenの名前、2つ目にURLを指定してください。" | |
exit 1 | |
fi | |
SCREEN_NAME=$1 | |
shift | |
# shellcheck disable=SC2068 | |
screen -dmS "${SCREEN_NAME}" /usr/bin/yt-dlp -o "/mnt/hdd/yt-dlp-live/%(title)s.%(ext)s" --hls-use-mpegts --wait-for-video 10 $@ |
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
import json | |
def json2csv(username: str): | |
with open("data/" + username + ".json") as f: | |
items = json.load(f) | |
rows = [] | |
for item in items: | |
for result in item["results"]: |
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
# 自動的にbook000をレビュアーにする | |
# book000, renovate, github-actionsからのPull-Requestにはレビュアーを追加しない | |
# 次の設定が必要: | |
# Settings -> Actions -> General -> Fork pull request workflows from outside collaborators -> Require approval for first-time contributors who are new to GitHub | |
name: Add reviewer | |
on: | |
pull_request_target: |
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
@echo off | |
git fetch --all | |
git checkout master | |
git fetch --prune | |
bash -c "git branch --merged | egrep -v '\*|develop|main|master'| xargs git branch -d" |
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
npx depcheck --json | jq -r .dependencies[] | xargs yarn remove | |
npx depcheck --json | jq -r .devDependencies[] | xargs yarn remove |
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
<?php | |
/* | |
plugins-oldディレクトリに古いプラグインjarをすべて入れて、実行するとplugin.ymlの内容をもとに関連サイトを開いたり、ダウンロード処理を行ったりする | |
*/ | |
function getFiles($dir) | |
{ | |
$files = scandir($dir); | |
$files = array_diff($files, array('.', '..')); | |
$files = array_filter($files, function ($file) use ($dir) { |
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
<?php | |
/* | |
あ~んをフォントを指定して絵文字画像を作成するPHPスクリプト (GD使用) | |
- Created by Tomachi https://gist.github.com/book000/16ff21e6916ae94033dfeba27a20eb90 | |
PREFIX_images ディレクトリに50枚の画像が生成されます。 | |
PREFIX_emojis.txt には絵文字の一覧を示すメッセージ用テキストが生成され出力されます。 | |
stdout には50音表に並んだ絵文字表が出力されます。 | |
*/ |
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
// ==UserScript== | |
// @name Reggae One💢 | |
// @namespace https://tomacheese.com | |
// @version 1.0.0 | |
// @description The world is made up of ANGER. | |
// @author Tomachi | |
// @match http://*/* | |
// @match https://*/* | |
// @updateURL https://gist.github.com/book000/e84ca5eb8715686d3d077311d3363411/raw/reggae-one.user.js | |
// @icon https://emojipedia-us.s3.dualstack.us-west-1.amazonaws.com/thumbs/120/apple/285/anger-symbol_1f4a2.png |