File: README.md

package info (click to toggle)
node-yarnpkg 4.1.0%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 24,752 kB
  • sloc: javascript: 38,953; ansic: 26,035; cpp: 7,247; sh: 2,829; makefile: 724; perl: 493
file content (27 lines) | stat: -rw-r--r-- 643 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# `@yarnpkg/plugin-patch`

This plugin adds support for the `patch:` protocol.

## Install

This plugin is included by default in Yarn.

## Usage

1. Run `yarn patch <package name>` and edit the resulting folder.

2. Once you're ready, run `yarn patch-commit -s <patch folder>` to store the result inside a `.patch` file.

3. Add the `patch:` protocol to your dependencies as such:

```json
{
  "dependencies": {
    "lodash": "patch:lodash@1.0.0#./my-patch-file.patch"
  }
}
```

## Caveat

You cannot add dependencies through the `patch:` protocol. Check this [FAQ entry](https://yarnpkg.com/features/patching#limitations) for more details.