summaryrefslogtreecommitdiff
path: root/xmake/modules/private/utils
diff options
context:
space:
mode:
authorruki <[email protected]>2023-08-15 09:15:42 +0800
committerGitHub <[email protected]>2023-08-15 09:15:42 +0800
commit6061906acf2d05cd207e79c1934b208cfac337df (patch)
tree170a661bb71dbdc1efec1919aca20d6a118ad839 /xmake/modules/private/utils
parent7d1358fbf7e14dc04512009ba5f41216d7392980 (diff)
parent52e9844649f68d700db373d20e27ba635869aacd (diff)
Merge pull request #4074 from SirLynix/SirLynix-patch-1
Order target names in help menu
Diffstat (limited to 'xmake/modules/private/utils')
-rw-r--r--xmake/modules/private/utils/complete_helper.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/xmake/modules/private/utils/complete_helper.lua b/xmake/modules/private/utils/complete_helper.lua
index 2816de056..ca187467c 100644
--- a/xmake/modules/private/utils/complete_helper.lua
+++ b/xmake/modules/private/utils/complete_helper.lua
@@ -28,7 +28,7 @@ function targets()
{
function ()
config.load()
- return table.keys(project.targets())
+ return table.orderkeys(project.targets())
end
}
end
@@ -41,7 +41,7 @@ function runable_targets(complete, opt)
config.load()
local targets = project.targets()
local runable = {}
- for k, v in pairs(targets) do
+ for k, v in table.orderpairs(targets) do
if (v:script("run") or v:is_binary()) and (not complete or k:startswith(complete)) then
table.insert(runable, k)
end