Skip to content

Add Config Set import/export feature#9712

Open
OursCodeur wants to merge 3 commits intoPathOfBuildingCommunity:devfrom
OursCodeur:add-config-import-export
Open

Add Config Set import/export feature#9712
OursCodeur wants to merge 3 commits intoPathOfBuildingCommunity:devfrom
OursCodeur:add-config-import-export

Conversation

@OursCodeur
Copy link
Copy Markdown
Contributor

@OursCodeur OursCodeur commented Mar 30, 2026

Added an import/export feature for the Configuration tab based on the existing solution for passive tree management, as well as a standard test spec set.

image image image image

Edit : updated the label misalignment.

Copy link
Copy Markdown
Member

@Wires77 Wires77 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm on the fence about this PR, mostly because I don't see much of a purpose in sharing configs vs. whole builds. How do you use this right now? I appreciate the test though

Comment thread src/Classes/ConfigTab.lua Outdated
Comment on lines +1036 to +1053
local newConfigSet = self:NewConfigSet(nil, controls.name.buf)
for _, child in ipairs(xmlConfigSet) do
if child.elem == "Input" and child.attrib.name then
if child.attrib.number then
newConfigSet.input[child.attrib.name] = tonumber(child.attrib.number)
elseif child.attrib.boolean then
newConfigSet.input[child.attrib.name] = child.attrib.boolean == "true"
elseif child.attrib.string then
newConfigSet.input[child.attrib.name] = child.attrib.string
end
elseif child.elem == "Placeholder" and child.attrib.name then
if child.attrib.number then
newConfigSet.placeholder[child.attrib.name] = tonumber(child.attrib.number)
elseif child.attrib.string then
newConfigSet.placeholder[child.attrib.name] = child.attrib.string
end
end
end
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like this section could be made into a function that could be called from Load in this same file. Similar to Save, otherwise we're just duplicating a lot of code.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Err good shout, and that'll make the spec file smaller too. I'll push something shortly.

@OursCodeur
Copy link
Copy Markdown
Contributor Author

OursCodeur commented Apr 17, 2026

I'm on the fence about this PR, mostly because I don't see much of a purpose in sharing configs vs. whole builds. How do you use this right now? I appreciate the test though

The main use case has been wanting to compare numbers from my imported char against a fully configured guide in another PoB window, and being lazy about setting it up the exact same way!

edit: it also happens to be n.1 in the medium requested features list, but I only saw it after submitting the PR and joining the Discord to say hi

@Wires77
Copy link
Copy Markdown
Member

Wires77 commented Apr 17, 2026

So the full build compare PR is here and I kind of wonder if the need for importing configs is going to go away once that's in, because then you could just compare the build in question instead of importing their configs. Importing configs might make more sense to just copy from the compared build instead of having this extra feature. If you open a PR for that approach I'll close this one and go with that instead

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants