summaryrefslogtreecommitdiff
path: root/xmake/core/base/process.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2017-08-16 15:35:31 +0800
committerruki <[email protected]>2017-08-16 15:35:31 +0800
commit19a8933bcbbd3513916ad3d0ec67ebf1bb8b88ec (patch)
tree91ca398588dc6d70efaba0ee33f2dc37c9dc3ac6 /xmake/core/base/process.lua
parent1801533d6ec2b2f981c58bf1a5a5e4aea56d633a (diff)
fix require print info
Diffstat (limited to 'xmake/core/base/process.lua')
-rw-r--r--xmake/core/base/process.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/xmake/core/base/process.lua b/xmake/core/base/process.lua
index 565eabbbb..297b8f696 100644
--- a/xmake/core/base/process.lua
+++ b/xmake/core/base/process.lua
@@ -40,6 +40,7 @@ function process.asyncrun(task, waitchars)
local waitindex = 0
local waitchars = waitchars or {'\\', '|', '/', '-'}
utils.printf(waitchars[waitindex + 1])
+ io.flush()
-- start and wait this task
local ok, errors = coroutine.resume(task)
@@ -47,6 +48,7 @@ function process.asyncrun(task, waitchars)
-- remove wait charactor
utils.printf("\b")
+ io.flush()
-- failed
return false, errors
@@ -58,6 +60,7 @@ function process.asyncrun(task, waitchars)
-- trace
waitindex = ((waitindex + 1) % #waitchars)
utils.printf("\b" .. waitchars[waitindex + 1])
+ io.flush()
-- wait some time
os.sleep(300)
@@ -68,6 +71,7 @@ function process.asyncrun(task, waitchars)
-- remove wait charactor
utils.printf("\b")
+ io.flush()
-- failed
return false, errors
@@ -76,6 +80,7 @@ function process.asyncrun(task, waitchars)
-- remove wait charactor
utils.printf("\b")
+ io.flush()
-- ok
return true