Skip to content

Commit

Permalink
init-nw.js: use octal literals
Browse files Browse the repository at this point in the history
  • Loading branch information
ngn committed Oct 22, 2015
1 parent d757233 commit aeb5356
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions init-nw.js
Original file line number Diff line number Diff line change
Expand Up @@ -384,10 +384,10 @@

var editor=process.env.DYALOG_IDE_EDITOR
if(editor){
var d=os.tmpDir()+'/dyalog';fs.existsSync(d)||fs.mkdirSync(d,0700)
var d=os.tmpDir()+'/dyalog';fs.existsSync(d)||fs.mkdirSync(d,0o700)
D.openInExternalEditor=function(ee,callback){ // ee: EditableEntity from RIDE protocol
var f=d+'/'+ee.name+'.dyalog'
fs.writeFileSync(f,ee.text,{encoding:'utf8',mode:0600})
fs.writeFileSync(f,ee.text,{encoding:'utf8',mode:0o600})
var env={};for(var k in process.env)env[k]=process.env[k];env.LINE=''+(1+(ee.currentRow||0))
var p=spawn(editor,[f],{env:env})
p.on('error',function(err){throw err})
Expand Down

0 comments on commit aeb5356

Please sign in to comment.