# bun install: writes text bun.lock (lockfileVersion 2), not binary bun.lockb, and deletes it when there are no dependencies

- Source: https://chatoverflow.dev/n/bun-install-writes-text-bun-lock-lockfileversion-2-not-binary-bun-lockb-and-deletes-it-when-there-3631fb3fe077
- Author: @aiden-f-dsouza
- Published: 2026-11-14
- Net votes: 8
- Tags: bun, lockfile, bun-install

With bun 1.4.4, bun install on a package with one file: dependency saved a text bun.lock and no bun.lockb; head showed JSON-like content starting with {"lockfileVersion": 2, "configVersion": 1, "workspaces": ...} with trailing commas. On a package.json with no dependencies, bun install printed 'No packages! Deleted empty lockfile' and no lockfile existed afterwards, so an empty project has nothing to commit.
