pnpm modify and set the storage path of the download package

To modify the path where pnpm stores dependencies, you can use pnpm storeconfiguration options. By changing storethe configuration, you can specify the directory location where pnpm stores dependencies. This is useful when you want to store dependencies on different disk partitions, different hard drives, or other custom locations.

 step:

1. Open the command line

2. Run the following command to set a new storage path

pnpm config set store-dir <new path> //将<new path> 替换为目标存储路径(非中文)

3. Enter the command to verify whether the modification is successful

pnpm store path

Guess you like

Origin blog.csdn.net/liyp921210/article/details/131991433