tssetup
PowerShellやCMDから1コマンドで、Bun + TypeScript の高速なフロントエンド開発環境(ホットリロードサーバー内蔵)を初期構築するツールです。
🚀 特徴
- 瞬時にプロジェクト開始: フォルダ作成、
bun init、tsconfig.jsonの設定、ホットリロードサーバースクリプトの作成を自動で一括実行します。 - 多彩な初期テンプレート:
default: Destyle.css を内包したシンプルな構成(ダークモード対応)。tailwind: CDN版 Tailwind CSS が即座に使えるレイアウト構成。router: ライブラリを使わずに HTML5 History API を利用した、自作の超軽量 SPA ルーティング構成。empty: 最少構成(空の TypeScript ファイルとシンプルな HTML)。
- エディタ連携:
--codeオプションを付けるだけで、作成したプロジェクトフォルダを VS Code で即座に開きます。 - 自動バージョン確認: 実行時に最新バージョンを確認し、更新がある場合は通知します。
🛠️ インストール方法
npm(推奨):
npm i -g @lapius/tssetup
tssetup コマンドが使えるようになります(Node.js 18 以降が必要。本体はシステムの Python 3.9+ で動きます)。
pip:
pip install tssetup
⚙️ 動作に必要な環境(依存関係)
| ツール | 用途 | インストール |
|---|---|---|
| Python 3.9+ | tssetup 本体の実行 | python.org |
| Bun | プロジェクト初期化・TSコンパイル | powershell -c "irm bun.sh/install.ps1 | iex" |
| VS Code (任意) | --code オプション使用時 |
code.visualstudio.com |
⚡ 使い方と全パラメータ一覧
tssetup <プロジェクト名> [--mode <モード名>] [--title <タイトル名>] [--code]
引数なしで実行するとバージョン情報・開発者情報のインフォ画面が表示されます。
パラメータ(引数)詳細
| パラメータ | 短縮形 | 型 | 必須 | デフォルト値 | 説明 |
|---|---|---|---|---|---|
project_name |
- | string | はい | - | 作成するプロジェクトのフォルダ名 |
--mode |
-m |
string | いいえ | default |
テンプレートモード(default / tailwind / router / empty) |
--title |
-t |
string | いいえ | "Bun + TS App" |
<title> タグに埋め込むテキスト |
--code |
-c |
flag | いいえ | - | セットアップ完了後に VS Code で開く |
--version |
-v |
flag | いいえ | - | バージョンを表示 |
--help |
-h |
flag | いいえ | - | ヘルプを表示 |
コマンド実行例
# 標準テンプレートで作成
tssetup my-app
# Tailwind CSS 組み込み + VS Code で開く
tssetup my-app --mode tailwind --code
# 自作 SPA ルーター構成
tssetup my-app --mode router --title "マイSPAサイト"
# 最小構成
tssetup my-app --mode empty
📁 作成されるファイル構成
my-app/
├── src/
│ └── index.ts ← エントリポイント(--mode で内容が変わる)
├── dist/ ← tsc が自動生成するJS出力先
├── node_modules/ ← bun install が自動生成
├── index.html ← フロントエンドのHTML
├── server.ts ← ホットリロード対応の開発用Webサーバー
├── tsconfig.json ← TypeScript コンパイラ設定
└── package.json ← Bun プロジェクト設定
プロジェクト作成後は自動的にそのディレクトリへ移動します。そのまま tsbuild を実行すれば開発を始められます。
🔄 アップデート
npm で入れた場合:
npm i -g @lapius/tssetup
pip で入れた場合:
pip install --upgrade tssetup
どちらの場合も tssetup --update で、入れた方法に合わせて更新できます。
✉️ 問い合わせ先
- X (旧Twitter): @Lapius7
- GitHub Issues: Lapius7/tssetup/issues
⚠️ 免責事項
本ソフトウェアの使用によって生じた直接的・間接的な損害について、作者は一切の責任を負いません。自己責任のもとでご使用ください。
📄 ライセンス & コピーライト
本プロジェクトは MIT License のもとで公開されています。
Copyright (c) 2026 Lapius7
Metadata
Release files for tssetup 1.3.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| tssetup-1.3.7.tar.gz | 22.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| tssetup-1.3.7-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 37.8 kB
Release files / tssetup-1.3.7.tar.gz
| Download URL | tssetup-1.3.7.tar.gz |
|---|---|
| Size | 22.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6ee9bc15ebbbb0249feb2a68b05af161bcad7622433fa6f2c7be5ecc17dd8c5f
|
|
BLAKE2b-256 checksum How to use checksums |
acc42e2deb3c8461833b961beb0dc912c4b63555b6153b90abf36882eea0604f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 28, 2026.
Transparency logRelease files / tssetup-1.3.7-py3-none-any.whl
| Download URL | tssetup-1.3.7-py3-none-any.whl |
|---|---|
| Size | 15.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b8933d5f4497548110541e13867d30937557735ada2f6c86c3c52ce21b5e39ce
|
|
BLAKE2b-256 checksum How to use checksums |
8659e38ef384f3d0957714af73ba0c65ba3e7e8da2eb0d6bb76cb98546993a5e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 28, 2026.
Transparency log