Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Hi! I fixed some code for you! #1

Merged
merged 1 commit into from

3 participants

@node-migrator-bot

Hi!

I am migrationBot!

Did you know that path.{exists,existsSync} was moved to fs.{exists,existsSync}, and that tty.setRawMode(mode) was moved to tty.ReadStream#setRawMode() (i.e. process.stdin.setRawMode()) in node v0.8.0? Read more @API changes between v0.6 and v0.8

I automatically made some changes I think will help you migrate your codebase to node v0.8.0, please review these changes and merge them if you feel they are useful, If they are not you can ignore this Pull Request.

Have a Nice Day!

--migrationBot

@elving
Owner

Awesome, thanks! :)

@elving elving merged commit 281876e into elving:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jul 7, 2012
  1. @jfhbrook
This page is out of date. Refresh to see the latest.
Showing with 8 additions and 8 deletions.
  1. +4 −4 lib/glue.js
  2. +4 −4 lib/utils.js
View
8 lib/glue.js
@@ -51,7 +51,7 @@ function glueCSS(css) {
_file = utils.cleanURL(line.match(regexs.fileRegex)[0]);
fileUrl = path.join(srcDir, _file);
- if (path.existsSync(fileUrl)) {
+ if (fs.existsSync(fileUrl)) {
files.push(_file);
if(options.watch && watched.indexOf(_file) === -1) newFiles = true;
@@ -95,7 +95,7 @@ function watchFile(file) {
function createFiles() {
if (firstTime) console.log('');
- if (!path.existsSync(buildDir)) fs.mkdirSync('build');
+ if (!fs.existsSync(buildDir)) fs.mkdirSync('build');
fs.writeFileSync(buildCSS, code.glued, 'utf8');
utils.log('success', utils.colorize('blue', 'Glue ') + utils.colorize('green', firstTime ? 'created' : 'updated') + ' build/main.css');
@@ -123,12 +123,12 @@ module.exports = function(_options) {
buildCSS = path.join(buildDir, 'main.css')
- if (!path.existsSync(srcDir)) {
+ if (!fs.existsSync(srcDir)) {
utils.log('error', utils.colorize('red', 'Couldn\'t find directory: ' + srcDir));
process.exit(1);
}
- if (!path.existsSync(srcCSS)) {
+ if (!fs.existsSync(srcCSS)) {
utils.log('error', utils.colorize('red', 'Couldn\'t find the main.css file.'));
process.exit(1);
}
View
8 lib/utils.js
@@ -27,10 +27,10 @@ module.exports.createStructure = function (_path) {
src = path.join(_path, 'src');
build = path.join(_path, 'build');
- if (!path.existsSync(_path)) fs.mkdirSync(_path);
- if (!path.existsSync(src)) fs.mkdirSync(src);
- if (!path.existsSync(path.join(src, 'modules'))) fs.mkdirSync(path.join(src, 'modules'));
- if (!path.existsSync(build)) fs.mkdirSync(build);
+ if (!fs.existsSync(_path)) fs.mkdirSync(_path);
+ if (!fs.existsSync(src)) fs.mkdirSync(src);
+ if (!fs.existsSync(path.join(src, 'modules'))) fs.mkdirSync(path.join(src, 'modules'));
+ if (!fs.existsSync(build)) fs.mkdirSync(build);
fs.writeFileSync(
path.join(src, 'main.css'),
Something went wrong with that request. Please try again.