summaryrefslogtreecommitdiff
path: root/xmake/modules/utils/progress.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2025-10-29 22:39:08 +0800
committerruki <[email protected]>2025-10-29 10:37:58 +0800
commita0b1b3d0d2d1138856aed1cce9078247b94862e5 (patch)
tree22e8effba75fd99a1bba96b610f6a0f21a958ecc /xmake/modules/utils/progress.lua
parent88e30eca65d91dcdb569a866a35f5cc1d15c1f61 (diff)
hide cursor
Diffstat (limited to 'xmake/modules/utils/progress.lua')
-rw-r--r--xmake/modules/utils/progress.lua7
1 files changed, 7 insertions, 0 deletions
diff --git a/xmake/modules/utils/progress.lua b/xmake/modules/utils/progress.lua
index c291854ea..d17bd876b 100644
--- a/xmake/modules/utils/progress.lua
+++ b/xmake/modules/utils/progress.lua
@@ -155,6 +155,12 @@ function _show_progress_with_multirow_refresh(progress, format, ...)
_g.progress_lineinfos = progress_lineinfos
is_first = true
end
+ if is_first then
+ tty.cursor_hide()
+ os.atexit(function (ok, errors)
+ tty.cursor_show()
+ end)
+ end
-- show the total progress line
local linecount = _g.linecount or 0
@@ -219,6 +225,7 @@ function _show_progress_with_multirow_refresh(progress, format, ...)
_g.showing_without_scroll = false
_g.progress_lineinfos = nil
_g.linecount = 0
+ tty.cursor_show()
else
_g.showing_without_scroll = true
_g.linecount = linecount