Skip to content

refactor: migrate to pnpm - #141

Merged
RedStar071 merged 17 commits into
mainfrom
refactor/pnpm
Nov 27, 2025
Merged

RedStar071 merged 17 commits into
mainfrom
refactor/pnpm

Conversation

@RedStar071

Copy link
Copy Markdown
Member

This pull request migrates the project from Yarn to pnpm as the package manager and replaces the use of Yarn-specific tools and configurations with pnpm and Husky. It also updates the CI workflow, cleans up legacy files, and introduces several improvements for dependency management and developer experience.

Key changes include:

Migration from Yarn to pnpm:

  • Updated scripts in package.json to use pnpm instead of yarn for commands like build, dev, prisma:generate, and others. Added husky and pnpm as dependencies, and updated the packageManager and engines fields accordingly. [1] [2] [3] [4] [5]
  • Added .npmrc with pnpm-specific settings for hoisting and workspace checks.

Husky and Git Hooks Integration:

  • Added Husky scripts and configuration files (.husky/commit-msg, .husky/pre-commit, .husky/install.mjs) to manage git hooks using pnpm and lint-staged, replacing the old Yarn-based hooks. [1] [2] [3]
  • Removed legacy Yarn git hooks and related plugin files (.github/hooks/commit-msg, .github/hooks/pre-commit, .yarn/plugins/@yarnpkg/plugin-git-hooks.cjs). [1] [2] [3]
  • Removed Yarn configuration file .yarnrc.yml which referenced the old hooks and plugins.

Continuous Integration Workflow Updates:

  • Updated .github/workflows/continuous-integration.yml to use pnpm for installing dependencies, generating Prisma types, and running scripts. Also updated to use Node.js matrix and pnpm caching.

General Cleanup:

  • Removed Gitpod Yarn install task from .gitpod.yml as part of the migration.

These changes collectively modernize the project's dependency management and CI process, streamline git hook handling, and improve overall developer experience.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This pull request migrates the project from Yarn to pnpm as the package manager, replacing Yarn-specific tools with pnpm and Husky for git hooks management. The migration includes updates to scripts, CI workflows, and configuration files.

Key changes:

  • Replaced all yarn commands with pnpm equivalents in package.json scripts and CI workflows
  • Migrated from Yarn's git hooks plugin to Husky v9 for managing pre-commit and commit-msg hooks
  • Updated CI workflows to use pnpm action and caching, with matrix strategy for better organization
  • Removed legacy Yarn configuration files (.yarnrc.yml, Yarn plugins) and replaced with pnpm configuration (.npmrc)

Reviewed Changes

Copilot reviewed 12 out of 15 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
package.json Updated all scripts to use pnpm, added husky dependency, configured packageManager and engines for pnpm, added postinstall and prepare scripts
.yarnrc.yml Removed Yarn configuration file
.yarn/plugins/@yarnpkg/plugin-git-hooks.cjs Removed Yarn git hooks plugin
.npmrc Added pnpm configuration for hoisting and workspace settings
.husky/pre-commit Added Husky pre-commit hook for lint-staged
.husky/commit-msg Added Husky commit-msg hook for commitlint
.husky/install.mjs Added install script to skip Husky in production/CI
.gitpod.yml Removed Gitpod Yarn install task
.github/workflows/continuous-integration.yml Updated to use pnpm with action-setup, matrix strategy, and pnpm caching
.github/workflows/continuous-delivery.yml Added HUSKY=0 environment variable to disable Husky in CI
.github/hooks/pre-commit Removed legacy Yarn pre-commit hook
.github/hooks/commit-msg Removed legacy Yarn commit-msg hook

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .husky/install.mjs Resolved
@RedStar071 RedStar071 closed this Nov 16, 2025
@RedStar071 RedStar071 reopened this Nov 16, 2025

@lorypelli lorypelli left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@RedStar071
RedStar071 merged commit 5c8c619 into main Nov 27, 2025
@RedStar071
RedStar071 deleted the refactor/pnpm branch November 27, 2025 22:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants