> ## Documentation Index
> Fetch the complete documentation index at: https://docs.talosjs.com/llms.txt
> Use this file to discover all available pages before exploring further.

# update

> Update Bun dependencies after auditing the resolved versions.

Update workspace dependencies with `bun update`. Unless you skip the audit, Talos first resolves the updated graph with `bun update --lockfile-only`, audits it, and rolls `package.json` and lockfiles back if the update is blocked.

## Usage

```bash theme={null}
talos update [options]
```

## Examples

Update every dependency allowed by the current ranges:

```bash theme={null}
talos update
```

Update selected dependencies only:

```bash theme={null}
talos update --deps=PACKAGE_ONE,PACKAGE_TWO
```

Update to latest versions, ignoring the ranges in `package.json`:

```bash theme={null}
talos update --latest
```

Update anyway when the audit finds vulnerabilities:

```bash theme={null}
talos update --deps=PACKAGE_NAME --force
```

Skip the audit and run `bun update` directly:

```bash theme={null}
talos update --skip-audit
```

## Options

| Option          | Description                                                                                    | Default           |
| --------------- | ---------------------------------------------------------------------------------------------- | ----------------- |
| `--deps`        | Comma-separated dependencies to update.                                                        | Every dependency  |
| `--latest`      | Update to the latest version, ignoring the range in `package.json`.                            | `false`           |
| `--force`       | Update anyway when the audit finds vulnerable dependencies, or when the audit cannot complete. | `false`           |
| `--audit-level` | Minimum severity that blocks the update: `low`, `moderate`, `high`, or `critical`.             | `high`            |
| `--skip-audit`  | Skip the vulnerability audit and update directly.                                              | `false`           |
| `--no-cache`    | Bypass the cached audit result and re-query OSV.dev.                                           | `false`           |
| `--cwd`         | Working directory to update in.                                                                | Current directory |

## Rollback

Before resolving audited updates, Talos snapshots `package.json`, `bun.lock`, `bun.lockb`, and `package-lock.json`. If the audit blocks the update and you did not pass `--force`, those files are restored to their previous contents.

## Caching

Audit results are cached at `var/cache/security/update-audit.json`. The cache key includes the resolved lockfile hash and the audit level.

## Output

The audit report prints the number of modules and dependencies scanned. Findings are grouped by module and include severity, package, advisory title, source, advisory id, patched version when available, and advisory URL.
