mirror of
https://github.com/idris-lang/Idris2.git
synced 2024-12-25 20:51:43 +03:00
473b8ee740
Translate node error codes Strip 'b' from flags Simplify directory wrangling in chez016
22 lines
378 B
JavaScript
22 lines
378 B
JavaScript
const support_system_directory_fs = require("fs");
|
|
|
|
function support_system_directory_changeDir(d){
|
|
try{
|
|
process.chdir(d);
|
|
return 0n
|
|
}catch(e){
|
|
process.__lasterr = e;
|
|
return 1n
|
|
}
|
|
}
|
|
|
|
function support_system_directory_createDir(d){
|
|
try{
|
|
support_system_directory_fs.mkdirSync(d)
|
|
return 0n
|
|
}catch(e){
|
|
process.__lasterr = e;
|
|
return 1n
|
|
}
|
|
}
|