Permalink
Browse files

Debugging encoding issue

  • Loading branch information...
1 parent c85b402 commit 2486283b1fdd1113efb7b6c3339019fb395be7ea @chbrown committed Mar 11, 2012
Showing with 18 additions and 18 deletions.
  1. +17 −17 bin/dropyll
  2. +1 −1 package.json
View
34 bin/dropyll
@@ -68,23 +68,23 @@ function syncFiles(items, socket, callback) {
function jekyll(mode, socket, callback) {
var local_fullpath = options.local + options.dropbox;
- fs.readdir(local_fullpath, function(err, files) {
- var live = mode === 'live';
- socket.emit('log', 'running jekyll in directory: ' + local_fullpath + '\n');
- var jekyll = spawn('jekyll', [live ? '_live' : '_test'], {
- cwd: local_fullpath,
- env: process.env
- });
- jekyll.stdout.on('data', function (data) {
- socket.emit('log', 'jekyll >: ' + data + '\n');
- });
- jekyll.stderr.on('data', function (data) {
- socket.emit('log', 'jekyll 2>: ' + data + '\n');
- });
- jekyll.on('exit', function (code) {
- socket.emit('log', 'jekyll FINISHED! ' + code + '\n');
- callback(null);
- });
+ var live = mode === 'live';
+ socket.emit('log', 'running jekyll in directory: ' + local_fullpath + '\n');
+ var new_env = process.env;
+ new_env['LANG'] = 'en_US.utf8';
+ var jekyll_proc = spawn('jekyll', [live ? '_live' : '_test'], {
+ cwd: local_fullpath,
+ env: new_env
+ });
+ jekyll_proc.stdout.on('data', function (data) {
+ socket.emit('log', 'jekyll >: ' + data + '\n');
+ });
+ jekyll_proc.stderr.on('data', function (data) {
+ socket.emit('log', 'jekyll 2>: ' + data + '\n');
+ });
+ jekyll_proc.on('exit', function (code) {
+ socket.emit('log', 'jekyll FINISHED! ' + code + '\n');
+ callback(null);
});
}
View
2 package.json
@@ -1,7 +1,7 @@
{
"name": "dropyll",
"description": "Use Dropbox to edit your Jekyll website (with staging area)",
- "version": "0.1.2",
+ "version": "0.1.3",
"repository": { "type": "git", "url": "http://github.com/chbrown/dropyll.git" },
"homepage": "http://github.com/chbrown/dropyll",
"bin": { "dropyll": "./bin/dropyll" },

0 comments on commit 2486283

Please sign in to comment.