Opk is a beautiful, unified package management workflow that sits on top of existing ecosystems like npm, Bun, pnpm, Yarn, and Deno. It provides a consistent interface for installing, managing, and orchestrating dependencies across different runtimes and environments.
Rather than replacing existing package managers, Opk acts as a meta-layer that standardizes tooling, simplifies configuration, and enables reproducible, cross-manager workflows. It focuses on developer experience, deterministic installs, and ecosystem interoperability.
- Unified package management across multiple ecosystems
- Consistent dependency and script workflows
- Cross-manager compatibility and migration
- NEW in 0.5: Keep multiple package managers in sync
- Type-safe configuration and extensibility
- Reproducible and deterministic environments
- Build the best GUI for package management
Opk enables developers to manage their packages at once and run them anywhere.
Opk CLI is an npm package that should be installed globally.
npm i -g opk-pmopk add <pkg...>- Add packages via selected package manager, then sync+generateopk remove <pkg...>- Remove packages via selected package manager, then sync+generateopk install- Install via selected package manager, then sync+generateopk update [pkg...]- Update via selected package manager, then sync+generateopk audit- Audit via selected package manager, then sync+generate
opk run <script> [args...]- Run scripts via selected package manageropx <cmd> [args...]- Execute binaries via selected package manager
opk init- Prompt for project metadata, writepackage.ts, run ts-pkg sync+generateopk migrate- Migrate from an existingpackage.jsontopackage.ts, then sync+generateopk generate [configPath] [packageJsonPath]- Generatepackage.jsonfrom ts-pkg configopk sync [configPath] [packageJsonPath]- Sync and regenerate using ts-pkg APIsopk gui [--port <port>]- Serve the built Opk GUI (defaults to port4173)
opk list- Show dependencies in a native opk UIopk info <pkg>- Show package info in a native opk UIopk outdated [--table|--list]- Show outdated dependencies in a native opk UI
These flags are mapped by Opk to the selected package manager's native flag equivalents:
--lock-only,--frozen-lockfile(foropk install,opk update)--ignore-scripts,--ignore-engines,--ignore-optional(foropk add|install|update)--ignore-workspace-root-check,--ignore-pnp(foropk add|install|update)--production/--prod,--dev,--peer,--optional(foropk add|install|update)--verbose,--silent(foropk add|remove|install|update|audit)
Examples:
opk add react --dev --ignore-scripts
opk install --frozen-lockfile --silent
opk update --lock-only --verbosebun run buildnow builds the CLI and the GUI, and stages GUI assets intodist/guiforopk gui.
import { definePackage, BunPm } from '@opk/ts-pkg'
export default definePackage({
pm: BunPm,
name: 'my-awesome-project',
description: 'this is an amazing project',
license: 'MIT',
type: 'module',
})
