Open meghfossa opened 3 years ago
This PR aims to fix, case where yarn.lock is created by using local directory package.
For reproduction:
touch package.json
{ "name": "name", "description": "description", "version": "0.1.0", "private": true, "author": "example", "license": "UNLICENSED", "scripts": { "ci:format": "prettier --check './**/*.js{,x}'" }, "dependencies": { "custom-plugin": "file:./custom-plugin/" } }
Install dependencies with yarn install
yarn install
It should create following yarn.lock file:
yarn.lock
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. # yarn lockfile v1 "custom-plugin@file:./custom-plugin": version "0.0.0"
When above yarn.lock file is parsed, it leads to: File.UnknownRemoteType Error.
File.UnknownRemoteType
It creates new Remote type for DirectoryLocal. This allows for successful parsing.
Remote
DirectoryLocal
Tagging you @Profpatsch for PR review.
This PR aims to fix, case where yarn.lock is created by using local directory package.
For reproduction:
touch package.json
Install dependencies with
yarn install
It should create following
yarn.lock
file:What happens currently?
When above
yarn.lock
file is parsed, it leads to:File.UnknownRemoteType
Error.What this PR does?
It creates new
Remote
type forDirectoryLocal
. This allows for successful parsing.