Hi there,
First of all, many thanks for such a great package!
I've encountered an issue with the rename() function that's returned via the link function. All of the other file system methods are working correctly, however, this one does not seem to maintain the path redirect.
For example:
const { link } = require('linkfs');
const fs = require('fs');
const linkedFs = link(fs, [[`${__dirname}/test`, `${__dirname}/dist`]]);
linkedFs.ReadStream = fs.ReadStream;
linkedFs.WriteStream = fs.WriteStream;
/* ---------------------------
*
* Correctly loads `./dist/package.json`
*
* ------------------------ */
console.log(linkedFs.readFileSync('./test/package.json', 'utf8'));
/* ---------------------------
*
* Incorrectly renames file to `./test/package-test.json` instead of `./dist/package-test.json`
*
* ------------------------ */
linkedFs.rename('./test/package.json', './dist/package-test.json', () => console.log('COPIED'));
Do you have any idea why this might be?
Many thanks for any help in advance, very much appreciated!
All the best
Hi there,
First of all, many thanks for such a great package!
I've encountered an issue with the
rename()function that's returned via thelinkfunction. All of the other file system methods are working correctly, however, this one does not seem to maintain the path redirect.For example:
Do you have any idea why this might be?
Many thanks for any help in advance, very much appreciated!
All the best