Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Support for creating a static package repo #402

Open
bos opened this Issue May 24, 2012 · 2 comments

Comments

Projects
None yet
1 participant
Contributor

bos commented May 24, 2012

(Imported from Trac #409, reported by mnislaih on 2008-11-19)

Usual scenario:

Bob has a bunch of packages for personal use he does not want or cannot upload to hackage. All he needs is a public_html folder, his packages in tar.gz files, and a bit of help to set up a private static hackage repo.

RubyGems allows this with the generate_index command, see here.

Since cabal-install supports multiple package sources already, the only thing missing is a command to generate the index and directory structure.

Contributor

bos commented May 24, 2012

(Imported comment by mnislaih on 2008-11-19)

I bit the bullet and hacked cabal-install to support this.
I extended cabal with a server command which expects to find the tar.gz files corresponding to packages in the current directory and will create the index file as well as the dir structure.

As cabal-install now by default uses the new hackage server directory structure and not the one described in [HackageDB], my patch tries hard to produce the former structure, so to avoid the need to patch the clients too.

A patch is attached. Although it is not very smart and will only work in Unix systems, it still could be useful to someone.

Contributor

bos commented May 24, 2012

(Imported comment by mnislaih on 2008-11-19)

updated to Cabal 1.8.0

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