I have been working with Foundation for Emails (1 and 2) for several months. I've added my projects to TFS (Team Foundation Server) to handle source control.
I have three projects setup. (One for each Brand)
Inside the respected Brand folder I have Foundation for Emails project created. As a test, I removed the npm node modules folder and the dist folder (as I want to exclude those from souce control) otherwise my team and I would be running into conflicts all the time. I added the folders successfully to TFS and then opened the Command Line to go to the folder where one of my projects lives.
I ran the npm install command (to get all the node modules I removed) and it looked into the package.json file and downloaded all the dependencies that made it work. However, it error out when I tried to inline. I got the following message:
Microsoft Windows [Version 6.3.9600] (c) 2013 Microsoft Corporation. All rights reserved. C:\Windows\system32>cd .. C:\Windows>cd .. C:\>cd source/main C:\source\main>cd src C:\source\main\src>cd emails C:\source\main\src\emails>cd tacticalgear C:\source\main\src\emails\tacticalgear>foundation build > [email protected] build C:\source\main\src\emails\tacticalgear > gulp --production [10:13:33] Failed to load external module babel-register [10:13:33] Requiring external module babel-core/register [10:13:36] Using gulpfile C:\source\main\src\emails\tacticalgear\gulpfile.babel.js [10:13:36] Starting 'default'... [10:13:36] Starting 'build'... [10:13:36] Starting 'clean'... [10:13:36] Finished 'clean' after 8.39 ms [10:13:36] Starting 'pages'... [10:13:39] Finished 'pages' after 2.51 s [10:13:39] Starting 'sass'... [10:13:39] Finished 'sass' after 134 ms [10:13:39] Starting 'images'... [10:13:39] gulp-imagemin: Minified 0 images [10:13:39] Finished 'images' after 311 ms [10:13:39] Starting 'inline'... [10:13:41] 'inline' errored after 1.33 s [10:13:41] Error: EPERM: operation not permitted, open 'C:\source\main\src\emails\tacticalgear\dist\review\index.html' at Error (native) [10:13:41] 'build' errored after 4.3 s [10:13:41] 'default' errored after 4.3 s Error: [email protected] build: `gulp --production` Exit status 1 at EventEmitter.<anonymous> (C:\Users\corey\AppData\Roaming\npm\node_modules\foundation-cli\node_modules\npm\lib\utils\lifecycle.js:217:16) at emitTwo (events.js:87:13) at EventEmitter.emit (events.js:172:7) at ChildProcess.<anonymous> (C:\Users\corey\AppData\Roaming\npm\node_modules\foundation-cli\node_modules\npm\lib\utils\spawn.js:24:14) at emitTwo (events.js:87:13) at ChildProcess.emit (events.js:172:7) at maybeClose (internal/child_process.js:827:16) at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5) C:\source\main\src\emails\tacticalgear>
Based on the error, it seems to be a permission issue. The problem is that the dist folder is inheritting permissions from the folder that it sits inside of (because it's part of TFS). Even though I have the dist folder excluded from TFS, the folder that gets added / deleted is inheriting permissions from the folder that it sits inside of. So I'm at a loss as to how to combat that problem?