-
-
Notifications
You must be signed in to change notification settings - Fork 78.9k
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
Fix #12603: add build-raw-files log #12672
Conversation
fs.writeFileSync(rawFilesJs, files); | ||
if (fs.existsSync(rawFilesJs)) { | ||
console.log('File ' + rawFilesJs.cyan + ' created'); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't suppose this could fail? If so maybe we should show an message in that case too.
grunt.log.write('File ' + rawFilesJs.cyan + ' created.'); | ||
} | ||
else { | ||
grunt.log.error('File ' + rawFilesJs + ' doesn\'t exist.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe "Error creating file ."? Current error message is kinda misleading.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hm hm. But we already have raw-files pre-built, so 'not created' can't
happen.
2014-02-10 8:08 GMT+01:00 Chris Rebert [email protected]:
In grunt/bs-raw-files-generator.js:
@@ -28,5 +29,12 @@ module.exports = function generateRawFilesJs(banner) {
banner = ''
}
var files = banner + getFiles('js') + getFiles('less') + getFiles('fonts')
- fs.writeFileSync('docs/assets/js/raw-files.min.js', files)
- var rawFilesJs = 'docs/assets/js/raw-files.min.js';
- fs.writeFileSync(rawFilesJs, files);
- if (fs.existsSync(rawFilesJs)) {
- grunt.log.write('File ' + rawFilesJs.cyan + ' created.');
- }
- else {
- grunt.log.error('File ' + rawFilesJs + ' doesn't exist.');
Maybe "Error creating file ."? Current error message is kinda misleading.
—
Reply to this email directly or view it on GitHubhttps://github.com//pull/12672/files#r9575465
.
Zlatan Vasović - ZDroid
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a valid point @zdroid :P
LGTM. Ideally I'd like to skip creating that file since it just gets minified later on.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yay. In that case we should just make raw-files as a string, nothing more.
2014-02-10 8:38 GMT+01:00 XhmikosR [email protected]:
In grunt/bs-raw-files-generator.js:
@@ -28,5 +29,12 @@ module.exports = function generateRawFilesJs(banner) {
banner = ''
}
var files = banner + getFiles('js') + getFiles('less') + getFiles('fonts')
- fs.writeFileSync('docs/assets/js/raw-files.min.js', files)
- var rawFilesJs = 'docs/assets/js/raw-files.min.js';
- fs.writeFileSync(rawFilesJs, files);
- if (fs.existsSync(rawFilesJs)) {
- grunt.log.write('File ' + rawFilesJs.cyan + ' created.');
- }
- else {
- grunt.log.error('File ' + rawFilesJs + ' doesn't exist.');
That's a valid point @zdroid https://github.com/ZDroid :P
LGTM. Ideally I'd like to skip creating that file since it just gets
minified later on.—
Reply to this email directly or view it on GitHubhttps://github.com//pull/12672/files#r9575730
.
Zlatan Vasović - ZDroid
@zdroid: can you rebase this against the latest master? |
@XhmikosR Yes, just a sec. |
Fix #12603.