Skip to content

Instantly share code, notes, and snippets.

このGASプロジェクトについて、下記の技術スタックに移行、もしくは採用済みの場合は維持したいです。下記の提案を評価し、妥当であれば実装してください。また、修正・追加の提案があればそれを実装してください。

領域 最終選定 選定の理由
パッケージ管理 pnpm 依存関係が厳格(Phantom dependencyの防止)で、CI/CD環境やローカルでのインストールが最速。現在のモダンフロントエンド/Node開発の事実上の最適解。
開発言語 TypeScript GAS開発(@types/google-apps-script)において必須。型による安全性がなければ、長期的な保守は不可能。
リンター・フォーマッタ Biome ESLint + Prettierの組み合わせは既にレガシーになりつつある。Rust製で圧倒的に速く、設定が単一で済むBiomeが、新規の小〜中規模TSプロジェクトにおいては最良の選択。
テストフレームワーク Vitest node:test はTSを直接実行するための設定(tsx等)が煩雑。Vitestなら設定ゼロでTSのテストが爆速で動く。開発体験(DX)の観点で圧倒的に優位。
バンドラー (ビルド) esbuild + esbuild-gas-plugin GASの「トップレベルに関数を露出させなければトリガー実行できない」という特殊な仕様を、最も美しく安全に解決できる唯一の正解構成。Webpackより桁違いに速く、設定も数行で済む。
Gitフック (品質強制) Husky + lint-staged コミット前にBiomeを強制実行する仕組みとして、最も枯れており、どの開発者が参加しても迷わない業界標準。
import time
import subprocess
def call_popen():
subprocess.Popen(["sleep", "10"]);
def main():
print(1)
call_popen() # 即座に戻ってくる
print(2)
This file has been truncated, but you can view the full file.
<?php
function foo($bar) {
$arr = [
"x1"=>["foo"=>1,"bar"=>1,"baz"=>3,"qux"=>4,"quux"=>5,"corge"=>6,"grault"=>7,"garply"=>8,"waldo"=>9,"fred"=>10,"plugh"=>11,"xyzzy"=>12,"thud"=>13],
"x2"=>["foo"=>2,"bar"=>1,"baz"=>3,"qux"=>4,"quux"=>5,"corge"=>6,"grault"=>7,"garply"=>8,"waldo"=>9,"fred"=>10,"plugh"=>11,"xyzzy"=>12,"thud"=>13],
"x3"=>["foo"=>3,"bar"=>1,"baz"=>3,"qux"=>4,"quux"=>5,"corge"=>6,"grault"=>7,"garply"=>8,"waldo"=>9,"fred"=>10,"plugh"=>11,"xyzzy"=>12,"thud"=>13],
"x4"=>["foo"=>4,"bar"=>1,"baz"=>3,"qux"=>4,"quux"=>5,"corge"=>6,"grault"=>7,"garply"=>8,"waldo"=>9,"fred"=>10,"plugh"=>11,"xyzzy"=>12,"thud"=>13],
"x5"=>["foo"=>5,"bar"=>1,"baz"=>3,"qux"=>4,"quux"=>5,"corge"=>6,"grault"=>7,"garply"=>8,"waldo"=>9,"fred"=>10,"plugh"=>11,"xyzzy"=>12,"thud"=>13],
"x6"=>["foo"=>6,"bar"=>1,"baz"=>3,"qux"=>4,"quux"=>5,"corge"=>6,"grault"=>7,"garply"=>8,"waldo"=>9,"fred"=>10,"plugh"=>11,"xyzzy"=>12,"thud"=>13],
"x7"=>["foo"=>7,"bar"=>1,"baz"=>3,"qux"=>4,"quux"=>5,"corge"=>6,"grault"=>7,"garply"=>8,"waldo"=>9,"fr
<?php
function foo($bar) {
return [
"x1"=>1,
"x2"=>1,
"x3"=>1,
"x4"=>1,
"x5"=>1,
"x6"=>1,
"x7"=>1,
*** ext/date/lib/unixtime2tm.c~ 2019-08-28 12:01:15.000000000 +0900
--- ext/date/lib/unixtime2tm.c 2019-12-11 20:37:52.000000000 +0900
***************
*** 56,61 ****
--- 56,67 ----
cur_year += YEARS_PER_LYEAR_PERIOD * (tmp_days / DAYS_PER_LYEAR_PERIOD);
tmp_days -= DAYS_PER_LYEAR_PERIOD * (tmp_days / DAYS_PER_LYEAR_PERIOD);
}
+ printf("tmp_days=%lld, year=%lld\n", tmp_days, cur_year);
+ if (ts >= 0 && tmp_days == 0) {
@hnw
hnw / hoge.md
Last active June 13, 2019 02:19
{
   "foo": [3,4,5]
}
@hnw
hnw / 1092104.json
Last active January 25, 2024 07:42
{
"title": "Use Japanese Keyboard as US Keyboard",
"rules": [
{
"description": "Ctrl+@ to Escape",
"manipulators": [
{
"type": "basic",
"conditions": [
{
{
"title": "Use Japanese Keyboard as US Keyboard (rev 1)",
"rules": [
{
"description": "Ctrl+@ to Escape",
"manipulators": [
{
"type": "basic",
"from": {
"key_code": "open_bracket",
{
"title": "Remap Japanese Keyboard to US (rev 1)",
"rules": [
{
"description": "Ctrl+@ to Escape",
"manipulators": [
{
"type": "basic",
"from": {
"key_code": "open_bracket",
{
"title": "Remap Japanese Keyboard to US",
"rules": [
{
"description": "Ctrl+@ to Escape",
"manipulators": [
{
"type": "basic",
"from": {
"key_code": "open_bracket",