npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@glash/cli

v0.2.39

Published

glashDB command-line interface — deploy projects, pull source + env, manage env vars.

Readme

@glash/cli

The official command-line interface for glashDB.

Install

Pick whichever install style you prefer — all four produce the same glash command:

# Short-name (recommended)
npm install -g glashdb

# Scoped package
npm install -g @glash/cli@latest

# pnpm / yarn / bun
pnpm add -g glashdb
yarn global add glashdb
bun add -g glashdb

# No install — run on demand
npx -y glashdb deploy

Then:

glash login
glash deploy

glash: command not found

If npm says the install completed but your shell can't find glash, your npm global bin folder isn't on PATH. Fix it once:

npm list -g glashdb --depth=0          # confirm install
ls -la "$(npm prefix -g)/bin/glash"  # confirm bin exists
echo 'export PATH="$(npm prefix -g)/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc
hash -r
glash --version

On macOS with Homebrew Node, the global prefix is usually /opt/homebrew/bin (Apple Silicon) or /usr/local/bin (Intel) — both are typically already on PATH. With nvm, re-run nvm use in new shells or add nvm use --default to your shell init.

EACCES / permission errors

Don't sudo npm install -g. Instead, point npm at a user-owned prefix:

mkdir -p ~/.npm-global
npm config set prefix ~/.npm-global
echo 'export PATH="$HOME/.npm-global/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc
npm install -g glashdb

Deployable frameworks

glash deploy works with more than Next.js. For Node projects, glashDB can infer a build from package.json and your lockfile. For anything else, include a Dockerfile and glashDB will build and run the container.

Common Node and frontend targets:

| Framework or runtime | Notes | | --- | --- | | glashjs | Native glashDB framework support; the CLI detects glashjs/glash.config.* and packages build/start scripts when missing | | Next.js | Built and started with the Next runtime when no custom start script is present | | React | Works with Vite, Create React App, Gatsby, Remix, and custom React servers | | Vue | Works with Vue apps and Nuxt projects | | Svelte | Works with Svelte and SvelteKit projects | | Astro | Works for static or server-rendered Astro projects when the start command is configured | | Static sites | Plain HTML/CSS/JS, generated static output, and Hugo-style sites | | Node servers | Express, Fastify, NestJS, Hono, and other servers that expose a start script |

Containerized targets:

| Framework or runtime | Requirement | | --- | --- | | Django, FastAPI, Flask | Add a Dockerfile that starts the Python app | | Laravel, Rails | Add a Dockerfile with the app server and required runtime setup | | Go, Rust, Java, Spring | Add a Dockerfile that builds and runs the service | | Any custom runtime | Add a valid Dockerfile and expose the listening port |

Deployment checklist:

  • Add a build script if your app needs a production build.
  • Add a start script for Node apps, or provide server.js / index.js.
  • Add a Dockerfile for non-Node apps or custom runtime needs.
  • Set required secrets with glash env:add or the dashboard before deploying.
  • Make sure the app listens on the expected runtime port.
  • For large public/ folders, deploy with --asset-mode offload to upload public assets to glashDB object storage/CDN and keep the source bundle small.
  • Source bundles over 90 MB automatically use chunked source upload, keeping each request below Cloudflare Free's 100 MB upload limit.

Large public folders:

# Always offload public/ before building
glash deploy --asset-mode offload

# Offload only when public/ exceeds the threshold
glash deploy --asset-mode auto --asset-threshold 100mb

Every deploy prints a live monitor link. Open it to watch the black-screen deployment flow while the CLI is packaging, uploading, building, routing, and checking the live URL. Public asset offload prepares assets in small batches and uses multipart uploads for large files, so image/video-heavy public/ folders can upload without forcing the source bundle over the platform limit.

Framework/runtime checks:

glash deploy detects both the project framework and the runtime scripts in package.json. If they disagree, for example the project looks like Next.js but start calls glash serve, the CLI stops before upload and asks you to align the scripts or explicitly continue. Use --ignore-framework-mismatch only when the mismatch is intentional.

Large source bundles:

# Default: direct upload below 90 MB, chunked upload above it
glash deploy

# Force chunked upload even for a smaller bundle
glash deploy --source-upload chunked

# Tune the auto-chunk threshold
glash deploy --source-threshold 75mb

For glashjs projects, glash deploy detects glashjs or glash.config.mjs, marks the project as glashjs, keeps deploy-safe .glash output, and adds missing build / start scripts inside the deployment bundle without editing your local package.json.

Commands

| Command | Purpose | | --- | --- | | glash login | Sign in (stores a token at ~/.glash/credentials.json) | | glash logout | Clear local credentials | | glash whoami | Show the signed-in user | | glash projects | List your projects | | glash projects:new <name> | Create a project and link it to the current directory | | glash new <name> | Alias for projects:new | | glash new deploy | Deploy to a brand new project, ignoring any existing link | | glash projects:rm <slug> | Delete a project | | glash link <slug> | Link the current directory to an existing project | | glash open | Open the linked project's primary domain | | glash deploy [--prod] [--detach] | Deploy the linked project; streams the pipeline until live | | glash deploy --asset-mode offload | Upload public/ assets to object storage/CDN before zipping source | | glash deploy --source-upload chunked | Stage the source zip through multipart object storage to bypass Cloudflare's single-request cap | | glash deployments | List recent deployments | | glash status <id> | Show a deployment's pipeline + events | | glash logs <id> | Alias of status | | glash rollback <id> | Roll the linked project back to a previous deployment | | glash retry <id> [--fix <id>] | Retry a failed deployment | | glash env | List env vars for the linked project | | glash env:add KEY=value | Set a single env var | | glash env:rm KEY | Remove an env var | | glash env:pull [--out .env.local] | Pull env vars to a local file | | glash env:push [<file>] | Bulk upload from a .env file | | glash database dump [--url "$DATABASE_URL"] | Dump a Postgres-compatible source database to .glash/database-dumps/ | | glash database upload [--file dump.dump] | Restore a local dump into the linked glashDB database | | glash update | Update @glash/cli to the latest version |

Pass --project <slug> to any command to operate on a project other than the one linked in the current directory.

Database dump and upload

glash database dump looks for a Postgres-compatible source URL in this order:

  1. --url / --from
  2. the current shell environment
  3. .env, .env.local, .env.production, .env.development

Supported env names include DATABASE_URL, POSTGRES_URL, POSTGRES_URL_NON_POOLING, DIRECT_URL, and SUPABASE_DB_URL.

Examples:

glash database dump
glash database dump --url "$DATABASE_URL" --out ./backup.dump
glash database dump --format plain --out ./backup.sql

glash database upload restores the latest dump into the linked glashDB project. It fetches the project's revealed direct database URL from the glashDB API and runs pg_restore for custom dumps or psql for .sql dumps.

glash link my-project
glash database upload --yes
glash database upload --file ./backup.sql --format plain --project my-project

The commands require PostgreSQL client tools locally: pg_dump for dumps, pg_restore for custom-format restores, and psql for plain SQL restores.

Environment

| Variable | Default | Notes | | --- | --- | --- | | GLASH_API_URL | https://api.glashdb.com/api | Override the API base (self-hosted, staging) | | GLASH_APP_URL | https://glashdb.com | Override the dashboard base used for live monitor links | | GLASH_TOKEN | — | Use this token instead of ~/.glash/credentials.json (useful in CI) | | GLASH_ASSET_OFFLOAD_THRESHOLD | 100mb | Default threshold for glash deploy --asset-mode auto | | GLASH_ASSET_BATCH_SIZE | 50 | Number of public assets prepared per request during --asset-mode offload | | GLASH_SOURCE_UPLOAD_MODE | auto | Source upload mode: auto, direct, or chunked | | GLASH_SOURCE_UPLOAD_THRESHOLD | 90mb | Default threshold for automatic chunked source upload |

Requirements

Node.js 20+. Zero runtime dependencies.

License

Apache-2.0