diff options
| author | Akaps316 <[email protected]> | 2026-04-11 21:28:37 +0530 |
|---|---|---|
| committer | ruki <[email protected]> | 2026-04-20 09:35:36 +0800 |
| commit | f2179c9ccf0d199af1ea2c3320945f20a2f12f6e (patch) | |
| tree | c173df0a373be2a713eed0802151af8404baff0a /xmake/plugins/show/info | |
| parent | 8512dce671af24d2f293728bfdb9e65f81e5ed38 (diff) | |
Address code review feedback by waruqi: refactor parameter parsing, remove local functions, and use simpler test env
Diffstat (limited to 'xmake/plugins/show/info')
| -rw-r--r-- | xmake/plugins/show/info/depgraph.lua (renamed from xmake/plugins/show/info/target_graph.lua) | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/xmake/plugins/show/info/target_graph.lua b/xmake/plugins/show/info/depgraph.lua index 30c977fc3..cd5f3ad69 100644 --- a/xmake/plugins/show/info/target_graph.lua +++ b/xmake/plugins/show/info/depgraph.lua @@ -15,7 +15,7 @@ -- Copyright (C) 2015-present, Xmake Open Source Community. -- -- @author ruki --- @file target_graph.lua +-- @file depgraph.lua -- -- imports @@ -25,7 +25,7 @@ import("core.project.config") import("core.project.project") import("private.detect.check_targetname") -local function _collect_target_entry(target) +function _collect_target_entry(target) local deps = {} for _, dep in pairs(target:deps() or {}) do table.insert(deps, dep:name()) @@ -47,7 +47,7 @@ local function _collect_target_entry(target) } end -local function _collect_target_graph(root_target) +function _collect_target_graph(root_target) local targets = {} local selected = {} if root_target then @@ -91,7 +91,7 @@ local function _collect_target_graph(root_target) } end -local function _print_target_graph(graph) +function _print_target_graph(graph) print("The dependency graph of targets:") for _, target in ipairs(graph.targets) do local deps = #target.deps > 0 and table.concat(target.deps, ", ") or "(none)" |
