VFS(cont)

This commit is contained in:
Xuan Sang LE
2018-01-24 01:03:14 +01:00
parent a70f52f965
commit dfbeb16601
6 changed files with 34 additions and 19 deletions

View File

@ -2,13 +2,18 @@ self.OS.API.handler =
scandir: (p, c ) ->
path = "lua-api/fs/scandir"
_API.post path, { path: p }, c, (e, s) ->
_courrier.osfail "Fail to scan directory: #{path}", e, s
_courrier.osfail "Fail to scan directory: #{p}", e, s
fileinfo: (p, c) ->
path = "lua-api/fs/fileinfo"
_API.post path, { path: p }, c, (e, s) ->
_courrier.osfail "Fail to get file metadata: #{path}", e, s
_courrier.osfail "Fail to get file metadata: #{p}", e, s
readfile: (p, c) ->
path = "lua-api/fs/get/"
_API.get path + p, c, (e, s) ->
_courrier.osfail "Fail to read file: #{p}",e , s
scanapp: (p, c ) ->
path = "lua-api/system/application"
auth: (c) ->