diff --git a/INSTALL.md b/INSTALL.md index 1fba77b..eed21d5 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -10,6 +10,18 @@ bun add @coder/ghostty-web yarn add @coder/ghostty-web ``` +### Installing from Git + +You can install directly from GitHub: + +```bash +npm install github:coder/ghostty-web +# or +bun add github:coder/ghostty-web +``` + +**Note:** When installing from git, the package automatically builds itself via a `postinstall` script. This requires Bun to be installed and may take a few seconds during installation. + ## Basic Usage ```typescript diff --git a/README.md b/README.md index f9f40b8..03f977c 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,14 @@ A web-based terminal emulator that integrates [Ghostty's](https://github.com/gho npm install @coder/ghostty-web ``` +Or install from GitHub: + +```bash +npm install github:coder/ghostty-web +``` + +**Note:** Git installs will auto-build during `postinstall` (requires Bun). + ## Quick Start ```typescript diff --git a/package.json b/package.json index acba1e9..a497526 100644 --- a/package.json +++ b/package.json @@ -57,7 +57,8 @@ "fmt:fix": "prettier --write .", "lint": "biome check .", "lint:fix": "biome check --write .", - "prepublishOnly": "bun run test && bun run build" + "prepublishOnly": "bun run test && bun run build", + "postinstall": "[ -d dist ] || bun run build" }, "devDependencies": { "@biomejs/biome": "^1.9.4",