Groups in XCode workspace working.
This commit is contained in:
parent
1cddb0dffa
commit
79d1c6f429
@ -8,7 +8,7 @@
|
||||
|
||||
local p = premake
|
||||
local m = p.modules.xcode
|
||||
|
||||
local tree = p.tree
|
||||
|
||||
|
||||
---
|
||||
@ -53,18 +53,33 @@
|
||||
end
|
||||
|
||||
function m.workspaceFileRefs(wks)
|
||||
for prj in p.workspace.eachproject(wks) do
|
||||
p.push('<FileRef')
|
||||
local contents = p.capture(function()
|
||||
p.callArray(m.elements.workspaceFileRef, prj)
|
||||
end)
|
||||
p.outln(contents .. ">")
|
||||
p.pop('</FileRef>')
|
||||
end
|
||||
local tr = p.workspace.grouptree(wks)
|
||||
tree.traverse(tr, {
|
||||
onleaf = function(n)
|
||||
local prj = n.project
|
||||
|
||||
p.push('<FileRef')
|
||||
local contents = p.capture(function()
|
||||
p.callArray(m.elements.workspaceFileRef, prj)
|
||||
end)
|
||||
p.outln(contents .. ">")
|
||||
p.pop('</FileRef>')
|
||||
end,
|
||||
|
||||
onbranchenter = function(n)
|
||||
local prj = n.project
|
||||
|
||||
p.push('<Group')
|
||||
p.w('location = "container:"')
|
||||
p.w('name = "%s">', n.name)
|
||||
end,
|
||||
|
||||
onbranchexit = function(n)
|
||||
p.pop('</Group>')
|
||||
end,
|
||||
})
|
||||
end
|
||||
|
||||
|
||||
|
||||
---------------------------------------------------------------------------
|
||||
--
|
||||
-- Handlers for individual project elements
|
||||
|
Loading…
Reference in New Issue
Block a user