diff options
| author | ruki <[email protected]> | 2022-03-30 23:14:49 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2022-03-30 23:14:49 +0800 |
| commit | 06b374d6f1eb4b97f81dbcf9f5d528e3767981a1 (patch) | |
| tree | e0629c0c3490bec72ef0b202d5ffcd351e569ef0 | |
| parent | 0dab3adc402d63422384b7c3618118848f6bec2b (diff) | |
| parent | 38a8b1b5df206409c861b3f46efe9e99fd04e94f (diff) | |
Merge pull request #2226 from shuax/dev
Improve group name uuid
| -rw-r--r-- | xmake/plugins/project/vstudio/impl/vs201x_solution.lua | 6 | ||||
| -rw-r--r-- | xmake/plugins/project/vsxmake/getinfo.lua | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/xmake/plugins/project/vstudio/impl/vs201x_solution.lua b/xmake/plugins/project/vstudio/impl/vs201x_solution.lua index 7d285c154..c9dea0c34 100644 --- a/xmake/plugins/project/vstudio/impl/vs201x_solution.lua +++ b/xmake/plugins/project/vstudio/impl/vs201x_solution.lua @@ -72,7 +72,7 @@ function _make_projects(slnfile, vsinfo) local group_path = target:get("group") if group_path then for _, group_name in ipairs(path.split(group_path)) do - groups[group_name] = hash.uuid4(group_name) + groups[group_name] = hash.uuid4("group." .. group_name) end end end @@ -126,14 +126,14 @@ function _make_global(slnfile, vsinfo) if group_path then -- target -> group local group_name = path.filename(group_path) - slnfile:print("{%s} = {%s}", hash.uuid4(targetname), hash.uuid4(group_name)) + slnfile:print("{%s} = {%s}", hash.uuid4(targetname), hash.uuid4("group." .. group_name)) -- group -> group -> ... local group_names = path.split(group_path) for idx, group_name in ipairs(group_names) do local key = group_name .. (group_name_sub or "") local group_name_sub = group_names[idx + 1] if group_name_sub and not subgroups[key] then - slnfile:print("{%s} = {%s}", hash.uuid4(group_name_sub), hash.uuid4(group_name)) + slnfile:print("{%s} = {%s}", hash.uuid4(group_name_sub), hash.uuid4("group." .. group_name)) subgroups[key] = true end end diff --git a/xmake/plugins/project/vsxmake/getinfo.lua b/xmake/plugins/project/vsxmake/getinfo.lua index a9a5c1f9c..a2623f226 100644 --- a/xmake/plugins/project/vsxmake/getinfo.lua +++ b/xmake/plugins/project/vsxmake/getinfo.lua @@ -304,7 +304,7 @@ function _make_vsinfo_groups() for idx, name in ipairs(group_names) do local group = groups["group." .. name] or {} group.group = name - group.group_id = hash.uuid4(name) + group.group_id = hash.uuid4("group." .. name) if idx > 1 then group_deps["group_dep." .. name] = {current_id = group.group_id, parent_id = hash.uuid4(group_names[idx - 1])} end |
