From af9ffa418f6258a26d47ed6ce79d26eef77b56c4 Mon Sep 17 00:00:00 2001 From: ruki Date: Tue, 22 Oct 2019 22:35:56 +0800 Subject: fix confirm when redirecting output --- core/src/tbox/tbox | 2 +- xmake/core/base/utils.lua | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/src/tbox/tbox b/core/src/tbox/tbox index bfdcc3377..eb29b093a 160000 --- a/core/src/tbox/tbox +++ b/core/src/tbox/tbox @@ -1 +1 @@ -Subproject commit bfdcc33776c7e3c602ac7a4081ad17a365c02d8b +Subproject commit eb29b093abfeb7db2d7ae95892a055749df17af7 diff --git a/xmake/core/base/utils.lua b/xmake/core/base/utils.lua index 58721cc1e..878ca3c16 100644 --- a/xmake/core/base/utils.lua +++ b/xmake/core/base/utils.lua @@ -319,7 +319,7 @@ function utils.confirm(opt) -- get answer io.flush() - confirm = option.boolean(io.read():trim()) + confirm = option.boolean((io.read() or "false"):trim()) if type(confirm) ~= "boolean" then confirm = default end -- cgit v1.3.1