Updating project to use luarocks#34
Conversation
|
This is quite a big change and I haven't digested it all yet. Lets try to split this up into steps.
|
|
Hi @joto, Thanks for your feedback. I'm going to hopefully have some time this weekend to go through these items. I do agree that this is large, and I'm going to figure out how we can split this up and verify everything is be done in accordance to Lua best practices. Stay tuned for more updates 📺 📡 . |
|
Here's the requested proposal for the changes that was originally in the pull request changes: Proposal: LuaRocks PackagingSummaryReorganize osm2pgsql-themepark so it can be installed via LuaRocks ( ProblemCurrently users must:
There is no published LuaRocks package, no rockspec, and the theme discovery mechanism relies on a file-system path hack ( Solution
Goals
Non-Goals
Success Criteria
|
|
Here are my arguments for points 2 and 3: 2. Why add a
|
|
Now I am confused. I though the point of this exercise was to get the packages into LuaRocks? Now you are talking about Homebrew, apt, conda, etc. Those are all specific to certain operating systems or environments which would lead to a lot of confusion if some packages are here and others are there. And we'd have to convince them all that they should take those packages. That sound a lot more complicated than having them in LuaRocks!? |
|
I can understand your confusion. In this case, it's better to think about luarocks as a "build backend". You use it just like you would a I think the best way to understand all of this is by looking at it from the packager's point of view. Below is a link to how this would be packaged in conda: Because we have a luarocks file defined, we can use it as a build backend that exactly what you as the code author want any package manger to include. The above is similar to how you would package this for any packaging ecosystem. But this does depend on the user experience you utlimately want for osm2pgsql-themepark. Right now, I'm making the assumption that this is going to be bundled separately from osm2pgsql because it's seen as a addon. Is that true? Or would you ideally like this to bundled together everywhere with osm2pgsql? I'm currently the package maintainer for osm2pgsql on conda-forge, so we could experiment with bundling it there. If I was you though, I would keep this separate for the time being because it's still in beta. Hope this makes a little more sense now. Sorry for the confusion. |
Please see my original comment here for a little more context:
Description
To make this easier to package and distribute, I'm proposing that we update this repository to use a luarocks spec file. This pull request still needs some refine, and I am more than happy to do that. I just want to know whether this would even be considered at all.
Notable changes:
osm2pgsql-themepark-scm-1.rockspecTHEMEPARK_PATHenvironment variable for finding user defined themes.themes/into the thelua/folder so these default themes can appear in the package.I've left my implementation notes in the
.openspec/folder intact so you can have even more context around how everything works. We can of course remove this if we decide to merge this.Like I said in the comment above, I have a complete working example of all this in my CLI tool osmprj, so I'm feeling quite confident that this could be a worthwhile change.
More than happy to discuss further, and thank you so much for taking the time to read and consider this change 🙏.