This file contains hidden or 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 | |
import os | |
import sys | |
import json | |
import argparse | |
import requests | |
from pprint import pprint | |
from bs4 import BeautifulSoup |
This file contains hidden or 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 | |
namespace App; | |
use Illuminate\Database\Eloquent\Model; | |
class ConvertDate extends Model | |
{ | |
// 西暦を和暦に変換する |
This file contains hidden or 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 | |
import argparse | |
import chardet | |
import os | |
import re | |
import statistics | |
import sys | |
import xmltodict | |
import matplotlib.pyplot as plt |
This file contains hidden or 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
# ***** 設定 ***** | |
# 変更するフォント名 | |
font = 'Meiryo' | |
# Creative Cloud のパス | |
cc_path = r'C:\Program Files\Adobe\Adobe Creative Cloud' | |
# ***** 設定ここまで ***** |
This file contains hidden or 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
{ | |
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh3/main/themes/schema.json", | |
"console_title": true, | |
"console_title_style": "template", | |
"console_title_template": "{{.Shell}} : {{.Folder}}", | |
"blocks": [ | |
{ | |
"type": "prompt", | |
"alignment": "left", | |
"segments": [ |
This file contains hidden or 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
# Windows から WSL へポートフォワーディングを設定 | |
function Set-WslPortForwarding { | |
# WSL のディストリビューション | |
$wsl_distribution = 'Ubuntu'; | |
# WSL に割り当てられたローカルドメイン | |
$wsl_domain = 'ubuntu.wsl'; |
This file contains hidden or 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
/** | |
* WebGL で動画をキャプチャして Canvas に描画する試作品(失敗作) | |
* 元々 Safari で CanvasRenderingContext2D.drawImage() で MSE 経由の動画をキャプチャできないバグがあり、 | |
* WebGLRenderingContext.texImage2D() ならできるんじゃないかと試したときのもの | |
* macOS Safari では一応機能するが、キャプチャした瞬間映像が描画されなくなる | |
* (CSS ハックで強制的に repaint(再描画)をかける事でどうにかできなくはないが、30fps は出ない) | |
* iPadOS Safari ではキャプチャ自体が機能せず、CSS ハックも使えないので実質無意味 | |
* 参考: https://webglfundamentals.org/webgl/lessons/ja/webgl-image-processing.html | |
* 参考: https://medium.com/veltra-engineering/webgl-2d-a9c7a7d89fb8 | |
* @param {HTMLVideoElement} video |
This file contains hidden or 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
#!/usr/bin/env pwsh | |
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent | |
$exe="" | |
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) { | |
# Fix case when both the Windows and Linux builds of Node | |
# are installed in the same directory | |
$exe=".exe" | |
} | |
$ret=0 |
This file contains hidden or 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
# | |
# TSInfoExtractor.py | |
# Copyright (c) 2021-2022 tsukumi. Licensed under MIT. | |
# | |
import json | |
import sys | |
from copy import copy | |
from datetime import date | |
from datetime import datetime |
This file contains hidden or 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
/* ==UserStyle== | |
@name TwitterRevertColoring | |
@description Twitter の UI の配色を元に戻すユーザースタイル | |
@namespace https://gist.github.com/tsukumijima | |
@updateURL https://gist.github.com/tsukumijima/931905c4ed3f181ce926730463a29d80/raw/TwitterRevertColoring.user.css | |
@author tsukumi | |
@version 1.3.9 | |
@license MIT | |
==/UserStyle== */ |