Skip to content
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: store updates to package descriptions with Git as backend #36

Closed
Blaisorblade opened this issue Sep 1, 2013 · 4 comments
Closed

Comments

@Blaisorblade
Copy link

Hackage 2 allows some updates for the package descriptions for already uploaded package, and stores the various revisions. Could Hackage use Git as backend and push changes to a public readonly mirror somewhere? I imagine that people can easily take a look at it; and probably it would be somewhat easy, for instance, to use Git commit ids for people interested in repeatable builds.

I mentioned this today at Zurihac, but I fear I didn't explain myself clearly.

@dcoutts
Copy link
Contributor

dcoutts commented Sep 2, 2013

The right thing to do is to make all the revisions available via its general REST api and then anyone can mirror those wherever they like.

But doing the git thing directly is not something we plan to integrate into the server. The general design is to make all information available via the REST interface.

@Blaisorblade
Copy link
Author

The general design is to make all information available via the REST interface.

So I see it's possible to

  1. use the current backend
  2. implement (within Hackage) the REST interface, which I agree is needed anyway
  3. (even externally) implement a mirror to a git repo, as long as the load is not excessive (which hopefully is not a problem).

I agree you need a web frontend, but I think my proposal is not in conflict. I wonder what "all information" means: the core is a persistent map from packages and ids to cabal files, but will I (eventually) be able to look on Hackage at changes to those files among two snapshots of the map?

I suspected that using Git (or maybe other VCSs) as a backend would save effort anyway, because you can use it to implement efficiently the persistent map I mentioned above (encoding packages and ids as filenames) - and for instance with Git you get delta compression for free. By choosing that backend, one gets also everything else for free - like for instance for Homebrew (which might depend even more on Git, but that's not my point).

@Blaisorblade
Copy link
Author

Anyway, feel free to close the issue if you believe the idea isn't worthwhile.

@dcoutts dcoutts closed this as completed Sep 19, 2013
@dcoutts
Copy link
Contributor

dcoutts commented Sep 19, 2013

Yes, all the info should be available so that you or anyone could mirror the info into a git repo.

Currently the thing that is not available is the revisions, but that should be easy to fix, and we'd be happy to accept patches to do that.

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

No branches or pull requests

2 participants