summaryrefslogtreecommitdiff
path: root/xmake/modules
diff options
context:
space:
mode:
authorruki <[email protected]>2023-06-22 00:00:19 +0800
committerruki <[email protected]>2023-06-22 00:00:19 +0800
commitf6ab5618f9fe79edbb63546d94a52001e74dbce7 (patch)
tree13b775bf056aaaa4e07996789f63037e10a8e27c /xmake/modules
parent3160ed6c8a89270de985199b574fb10411a3a4e0 (diff)
check file type
Diffstat (limited to 'xmake/modules')
-rw-r--r--xmake/modules/private/utils/upgrade_vsproj.lua16
1 files changed, 15 insertions, 1 deletions
diff --git a/xmake/modules/private/utils/upgrade_vsproj.lua b/xmake/modules/private/utils/upgrade_vsproj.lua
index 9a8478d2c..ebd732c92 100644
--- a/xmake/modules/private/utils/upgrade_vsproj.lua
+++ b/xmake/modules/private/utils/upgrade_vsproj.lua
@@ -29,9 +29,23 @@ local options = {
, {nil, "vs_projectfiles", "vs", nil, "Set the solution or project files." }
}
+-- upgrade *.sln
+function _upgrade_sln(projectfile, opt)
+ opt = opt or {}
+end
+
+-- upgrade *.vcxproj
+function _upgrade_vcxproj(projectfile, opt)
+ opt = opt or {}
+end
+
-- upgrade vs project file
function upgrade(projectfile, opt)
- opt = opt or {}
+ if projectfile:endswith(".sln") then
+ _upgrade_sln(projectfile, opt)
+ elseif projectfile:endswith(".vcxproj") then
+ _upgrade_vcxproj(projectfile, opt)
+ end
end
-- https://github.com/xmake-io/xmake/issues/3871