-
Notifications
You must be signed in to change notification settings - Fork 704
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Proposal] Put each nimble package in its own file #777
Comments
You are talking about |
@Araq yep! |
Sure, we can do this :) |
The usual solution for large archieves is to precompute index files centrally (essentially a keyword -> package name k/v map) and ship those. Yet, we are not going to need this for quite a while! |
@FedericoCeratto You make a good point about the package scanner and it taking more time to do recursive walks, however, the main point (which I failed to emphasize) is the greater ease of use. It's not happening so much now, but when lots of users start submitting lots of packages to Nim, there are potentially going to be many PRs for Again, this is just an idea. If it makes things too difficult or my reasoning is faulty, maybe package.json fine the way it is. I haven't looked at the source, so maybe this is the most efficient way. |
One potential drawback with this proposal is that you won't be able to as easily add a new package using just the GitHub web interface. |
@dom96 that's true as well. It's pretty easy to just add a package like that. |
You can still fairly easily add new packages using the GitHub UI by clicking |
@euantorano that's a good point as well. I'm still a proponent of this change and I'll look into the effort when I have some time. |
@jyapayne I'll create a proposal on the Nimble issue tracker for a package publishing service. |
@FedericoCeratto that would be equally awesome! |
packages.json is getting big... Maybe just a single big directory were each package is a file? If we have sub directories package names can conflict without people knowing. |
Do people do that? :) I like the point one package per directory (or may be even a file?) rather than having to edit a humongous .json. |
proposal:
note:checking it in might make it simpler, eg so that nimble refresh only has to download 1 file file organization
|
Actually you can create files through web interface. |
You can also create a folder structure using tab though its not intuitive. |
Problems
Proposal Run a simple service similar to pypi.org to handle package creation/update and generate the indexes. Initially it could feed from GH and/or use GH as a backend to store the indexes. Future goals Moonshot goals Update from a conversation with Araq: |
Nothing is simpler than a directory structure. SQLite is a dependency and I would not wish to make Nimble depend on it. Everything else sounds good to me on the surface. It'll be the details of how you implement this that I may disagree with, but just go for it :) |
Any progress here? I'm learning Nim but found the package list is pretty ugly. Maybe we can separate it to single files in an other branch (using a script for migration), and compile them into a single json file using CI for backward compability. |
Proposal
Put each nimble package in its own file/directory, or let each user create a subdirectory for themselves and put each package into one file.
Benefits
Downsides
So what do you think? It's just an idea, but maybe it'll be of use?
The text was updated successfully, but these errors were encountered: