@alexilyaev/monorepo-utils
v0.1.2
Published
A CLI with a set of tools to halp manage dependencies in Monorepos.
Readme
monorepo-utils
A CLI with a set of tools to halp manage dependencies in Monorepos.
Usage: monorepo-utils [options] [command]
Utils for managing monorepos
Options:
-V, --version output the version number
-h, --help display help for command
Commands:
delete-lockfile-deps [options] Delete all dependencies from the repo lockfile matching a regex
Examples:
monorepo-utils delete-lockfile-deps -p "package-name" --dry-run
monorepo-utils delete-lockfile-deps -p "^@scope/" --dry-run
monorepo-utils delete-lockfile-deps -p "^@scope/package-name$" --dry-run
update-deps-to-exact [options] Update dependencies in package.json files to exact versions from the lockfile
Examples:
monorepo-utils update-deps-to-exact -p "package-name" --dry-run
monorepo-utils update-deps-to-exact -p "^@scope/" --dry-run
monorepo-utils update-deps-to-exact -p "^@scope/package-name$" --dry-run
setup-configs [options] Command template description
Examples:
monorepo-utils setup-configs
help [command] display help for commandDevelopment
Setup
pnpm install
pnpm build
# Install the package globally, needed for the e2e tests
pnpm i -g .Testing
pnpm watch
pnpm test- E2E tests run against the dist, so make sure it's up to date
When updating test/e2e/templates
pnpm setup-e2eUpdating Vitest Snapshots
pnpm test -- -uRunning the CLI in dev for a specific folder
pnpm dlx vite-node src/cli.ts update-deps-to-exact --cwd test/e2e/generated/[email protected]/04-pattern-scope-match --dry-runpnpm dlx vite-node src/cli.ts update-deps-to-exact --cwd test/e2e/generated/[email protected]/04-pattern-scope-match --dry-run -p "^type-fest$"