summaryrefslogtreecommitdiff
path: root/xmake/core/base/os.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2020-02-21 22:55:32 +0800
committerruki <[email protected]>2020-02-21 11:33:16 +0800
commiteef01795e14276dac1f904217585b9c9208441dd (patch)
tree1b2da414855210669d30f7afb36ca99414ded1f7 /xmake/core/base/os.lua
parent2ce8c14ab4cee3a5673aa24649196cb45dcc0426 (diff)
improve xmake lua and os.syserror
Diffstat (limited to 'xmake/core/base/os.lua')
-rw-r--r--xmake/core/base/os.lua6
1 files changed, 6 insertions, 0 deletions
diff --git a/xmake/core/base/os.lua b/xmake/core/base/os.lua
index de67d636b..68273b919 100644
--- a/xmake/core/base/os.lua
+++ b/xmake/core/base/os.lua
@@ -41,6 +41,12 @@ os._setenv = os._setenv or os.setenv
os._getenvs = os._getenvs or os.getenvs
os._readlink = os._readlink or os.readlink
+-- syserror code
+os.SYSERR_UNKNOWN = -1
+os.SYSERR_NONE = 0
+os.SYSERR_NOT_PERM = 1
+os.SYSERR_NOT_FILEDIR = 2
+
-- copy single file or directory
function os._cp(src, dst)