From fdff022d0732c24f8e2d8076896c2b44db03139b Mon Sep 17 00:00:00 2001 From: ruki Date: Sun, 30 Oct 2022 11:24:34 +0800 Subject: improve git fsmonitor --- xmake/modules/devel/git/push.lua | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'xmake/modules/devel/git/push.lua') diff --git a/xmake/modules/devel/git/push.lua b/xmake/modules/devel/git/push.lua index b56ea4059..02585f020 100644 --- a/xmake/modules/devel/git/push.lua +++ b/xmake/modules/devel/git/push.lua @@ -39,8 +39,16 @@ import("branch", {alias = "git_branch"}) function main(url, opt) opt = opt or {} local git = assert(find_tool("git"), "git not found!") - - local argv = {"push", url} + local argv = {} + if opt.fsmonitor then + table.insert(argv, "-c") + table.insert(argv, "core.fsmonitor=true") + else + table.insert(argv, "-c") + table.insert(argv, "core.fsmonitor=false") + end + table.insert(argv, "push") + table.insert(argv, url) if opt.force then table.insert(argv, "--force") end -- cgit v1.3.1