-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected files when installing a local module #1267
Comments
I believe that Yarn should support |
I faced with the same issue. It seems that Yarn still doesn't support |
Can this issue be fixed? As of v1.8.0, local module installs still do not respect |
.npmignore not working for v1.17.3
|
Still not working for 1.22.5 |
Just ran into this, thanks for leaving a trail. (Also, it means if you add a local reference to parent directory, which I was doing for CI purposes, you can end up with like a russian nesting doll situation of yourself inside yourself inside yourself). Anyone know if this has been dealt with in any way in any Yarn, whether 2+ or 1? The project I am currently in is still using yarn 1 "classic". |
Ah, this is actually a dup of #2822 which wound up with many more comments. Seems like it is def not solved in any yarn 1. :(. I am not sure if it's solved in any yarn 2+. |
Do you want to request a feature or report a bug?
bug
What is the current behavior?
In real time it may be tens, maybe even thousands of modules.
I'll give an easy example for clarity.
I have 2 local modules:
Both modules use
Git
without remote repo.my-module-1
is connected to themy-module-2
locally.Tree
my-module-1
:.npmignore
file content in themy-module-1
:Tree
my-module-2
:package.json
file content in themy-module-2
:When I install dependencies in
my-module-2
byyarn
i see tree:It turns out that
yarn
simply copies all folders and files from themy-module-1
.If the current behavior is a bug, please provide the steps to reproduce.
Install
yarn
bynpm
globally:Install dependencies in
my-module-2
byyarn
:What is the expected behavior?
Like
npm i
.Tree:
As you can see,
npm
don't copy all files and folders, because it uses file.npmignore
. Even if you are not using file.npmignore
, thennpm
still does not copy the folder.git
and uses.gitignore
for ignore.But
yarn
copies all. Maybe there is some kind of.yarnignore
?Please mention your node.js, yarn and operating system version.
The text was updated successfully, but these errors were encountered: