Closed isochronous closed 7 years ago
I'm not sure why this helped, but I found that this glob array (mostly) works:
var workingBowerGlobs = [
'ui/src/elements/**/bower.json',
'!ui/src/elements/bower_components/**/bower.json'
];
Unfortunately, I'm still getting a bunch of EPERM errors thrown by bower that don't happen if I just run bower install
normally from a terminal. This may not be your issue, but it's weird that they only happen when running bower install
through this plugin.
Sample of the errors (apologies for the horrible formatting, but that's how it looks in the terminal, too).
Error: EPERM: operation not permitted, rename 'C:\Users\SomeUser\.config\configstore\bower-github.json.604294665' -> 'C:\Users\SomeUser\.config\configstore\bower-github.js
^
Error: EPERM: operation not permitted, rename 'C:\Users\SomeUser\.config\configstore\bower-github.json.2655415739' -> 'C:\Users\SomeUser\.config\configstore\bower-github.jon'
Eson'
at Error (native)
EPERM at Error (native)
at Object.fs.renameSync (fs.js:681:18)
PERM at Object.fs.renameSync (fs.js:681:18)
at Function.writeFileSync [as sync] (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\node_modules\write-file-atomic\index.js:81:8)
EPERM: operation not permitted, rename 'C:\Users\SomeUser\.config\configstore\bower-github.json.4222190069' -> 'C:\Users\SomeUser\.config\configstore\bower-github.jso
at Function.writeFileSync [as sync] (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\node_modules\write-file-atomic\index.js:81:8)
at Object.create.all.set (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\node_modules\configstore\index.js:63:21)
n'
at Object.create.all.set (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\node_modules\configstore\index.js:63:21)
EPE at Object.Configstore (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\node_modules\configstore\index.js:28:11)
at Object.Configstore (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\node_modules\configstore\index.js:28:11)
RM: operation not permitted, rename 'C:\Users\SomeUser\.config\configstore\bower-github.json.1190275566' -> 'C:\Users\SomeUser\.config\configstore\bower-github.json'
at readCachedConfig (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\config.js:19:23)
at readCachedConfig (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\config.js:19:23)
at defaultConfig (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\config.js:11:12)
at defaultConfig (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\config.js:11:12)
at Object.<anonymous> (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\index.js:16:32)
at Object.<anonymous> (C:\Program Files (x86)\Nodist\bin\node_modules\bower\lib\index.js:16:32)
at Module._compile (module.js:409:26)
Stack trace:
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Object.Module._extensions..js (module.js:416:10)
I'm guessing that this issue is due to multiple calls to bower install
running in parallel, which is causing issues with file locking. An option to run them in series would maybe be a good idea. Since this issue is now completely different from the original complaint, I'm closing this thread, and may open another... though it appears this project has been abandoned, so I'll probably just try to roll my own custom solution.
@isochronous v1.0.0
is out now! The new version groups commands so it only runs for instance one npm install
and one bower install
in parallel, so per command it's run in series which solves your issue above.
Awesome, great news! Thanks so much :D On Thu, Mar 23, 2017 at 4:18 AM Joakim Carlstein notifications@github.com wrote:
@isochronous https://github.com/isochronous v1.0.0 is out now! The new version groups commands so it only runs for instance one npm install and one bower install in parallel, so per command it's run in series which solves your issue above.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/slushjs/gulp-install/issues/48#issuecomment-288647026, or mute the thread https://github.com/notifications/unsubscribe-auth/AAvR0R4CBpl7skWYr1lizKAQHRAdaFiIks5roirlgaJpZM4MdKGX .
Finally went back to using this, and though it seems to be working exactly as it should, I can't say the same for the stdout logging, which seems to be stripping line breaks from npm output. It's not a big deal, but it does making reading install logs rather challenging, as one line just runs into the next and line breaks happen wherever the column limit on the terminal is.
This is with: Gulp 3.9.1 Node 4.7.3 Gulp-install 0.6.0 Windows 10
We have a directory structure like this:
Where each entry prefixed with
+
is a folder. Every .bowerrc file specifies the install directory for bower to be theui/src/elements/bower_components
folder, so we can maintain consistent relative paths between all folders.The problem is that using the
**
wildcard in src globs doesn't work: