Skip to content
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

Wrong symlinks relative path for nested files #321

Open
p5yk0 opened this issue Jun 23, 2020 · 1 comment
Open

Wrong symlinks relative path for nested files #321

p5yk0 opened this issue Jun 23, 2020 · 1 comment

Comments

@p5yk0
Copy link

p5yk0 commented Jun 23, 2020

Let's say we have this stucture :

|- dest
|- src
   |- Gulpfile.js
   |- app
      |- index.js
      |- module
         |- a.js

I want to symlink all files in src/app into dest and keep the app structure :

gulp
 .src( '/absolute/path/to/src/app/**', { nodir:true } )
 .pipe(
     gulp.symlink(
         'absolute/path/to/dest',
         { overwrite:true, relativeSymlinks:true } )
  );

Now in folder dest I have :

index.js -> '../src/app/index.js'
module/

That is fine.

But in dest/module I have :

a.js -> ../app/module/a.js

instead of

a.js -> ../../app/module/a.js

It seems that the directories presents in file.relative are ignored.
Only the files in the root src directory have working symlinks. Symlinks created for src nested files are broken.

Is it a bug or I'm somehow missing something ?

With Gulp
CLI version: 2.3.0
Local version: 4.0.2

@phated phated added this to To do in v5 Oct 22, 2020
@phated phated removed this from To do in v5 Jun 12, 2023
@phated
Copy link
Member

phated commented Jun 12, 2023

I don't see a good way to resolve this. In 4.0.0, we'll support Vinyl objects that already have the symlink file set, so you can calculate it within your stream pipeline.

We'll revisit this post-gulp-v5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

No branches or pull requests

2 participants