CotEditor向けCatppuccinテーマを作った
CotEditor向けのCatppuccinテーマを作成した。初めてのOSS貢献。
Catppuccin
ここ数年ずっと Dracula テーマを使っていて、最近 Catppuccin に乗り換えた。ダーク/ライトモード両方に対応していて、パステルカラーでかわいい。
GitHub - catppuccin/catppuccin: 😸 Soothing pastel theme for the high-spirited!
😸 Soothing pastel theme for the high-spirited! Contribute to catppuccin/catppuccin development by creating an account on GitHub.
github.com
CotEditorにCatppuccinテーマを
最近使い始めてお気に入りのテキストエディタが CotEditor。macOS純正のアプリであるかのような美しいUIで、使いやすい。Markdownファイルを編集するのによく使ってる。
CotEditor
Text Editor for macOS
coteditor.com
ただ、調べたところCatppuccin公式ではCotEditorテーマが無い。非公式のものはあるけど、せっかくなら公式のものを使いたいよねってことで……

GitHub - catppuccin/coteditor: 🖊️ Soothing pastel theme for CotEditor
🖊️ Soothing pastel theme for CotEditor. Contribute to catppuccin/coteditor development by creating an account on GitHub.
github.com
自分で作ってみた。
公式のドキュメントに従ってリポジトリを作り、Issueを立てて、受けた指摘に従って修正して、リポジトリをTransferした。
catppuccin/docs/port-creation.md at main · catppuccin/catppuccin
😸 Soothing pastel theme for the high-spirited! Contribute to catppuccin/catppuccin development by creating an account on GitHub.
github.com
whiskers
Catppuccinには Latte、Frappé、Macchiato、Mochaという4つのフレーバーがあり、それぞれに対応するテーマファイルを用意する必要があった。
ここで興味深かったのが、Catppuccinでは whiskers というコマンドが用意されていて、 foobar.tera のようにテンプレートファイルを用意すれば、Catppuccinのフレーバー4つ分のテーマファイルを自動生成してくれること。4つ分のテーマファイルを一つずつ手で作らなくても良いらしい。
GitHub - catppuccin/whiskers: 😾 Soothing port creation tool for the high-spirited!
😾 Soothing port creation tool for the high-spirited! - catppuccin/whiskers
github.com
これのおかげで coteditor.tera を用意して、whiskers coteditor.tera を実行するだけで済んだ。すばらし~
ちなみに、 catwalk というのもあり、これを使うとフレーバー4つのスクリーンショットを合成して一つの画像にすることができる。
GitHub - catppuccin/catwalk: 🚶 Soothing pastel previews for the high-spirited!
🚶 Soothing pastel previews for the high-spirited! Contribute to catppuccin/catwalk development by creating an account on GitHub.
github.com
初のOSS貢献
これまでIssueを立てたりコメントをしたりしたことはあったけど、コードを書いてOSSに貢献したのは初めての経験だった。OSSのOrganizationに参加したのも初めてだし、OSSのメンテナーからコードに指摘をもらったのも、メンテナーに指定されたことも初めてだった。
友達でも同僚でもない、全然知らない海外の人とコミュニケーションを取って、指摘を受けて、褒められて。楽しいかも、これ。

うーん嬉しい。