Skip to content

Instantly share code, notes, and snippets.

@fictorial
Created December 8, 2009 14:34
Show Gist options
  • Save fictorial/251675 to your computer and use it in GitHub Desktop.
Save fictorial/251675 to your computer and use it in GitHub Desktop.
node> p=require('posix');
{
"Stats": [Function],
"close": [Function],
"closeSync": [Function],
"open": [Function],
"openSync": [Function],
"read": [Function],
"readSync": [Function],
"write": [Function],
"writeSync": [Function],
"rename": [Function],
"renameSync": [Function],
"rmdir": [Function],
"rmdirSync": [Function],
"mkdir": [Function],
"mkdirSync": [Function],
"sendfile": [Function],
"sendfileSync": [Function],
"readdir": [Function],
"readdirSync": [Function],
"stat": [Function],
"statSync": [Function],
"unlink": [Function],
"unlinkSync": [Function],
"cat": [Function]
}
node> s=p.stat('/tmp/foobar').wait()
{
"dev": 234881025,
"ino": 22624015,
"mode": 33204,
"nlink": 1,
"uid": 501,
"gid": 0,
"rdev": 0,
"size": 13,
"blksize": 4096,
"blocks": 8,
"atime": {},
"mtime": {},
"ctime": {},
"_checkModeProperty": [Function],
"isDirectory": [Function],
"isFile": [Function],
"isBlockDevice": [Function],
"isCharacterDevice": [Function],
"isSymbolicLink": [Function],
"isFIFO": [Function],
"isSocket": [Function]
}
node> s=p.statSync('/tmp/foobar');
Bus error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment