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

support file, directory and url targets for packages and .cabal files #517

Closed
bos opened this issue May 24, 2012 · 1 comment
Closed

support file, directory and url targets for packages and .cabal files #517

bos opened this issue May 24, 2012 · 1 comment

Comments

@bos
Copy link
Contributor

bos commented May 24, 2012

(Imported from Trac #524, reported by @dcoutts on 2009-03-16)

Currently the cabal program supports two ways to specify a package. One is implicitly to look in the current directory for a .cabal file. The other is a package name (actually a dependency) which we look for in the current set of repositories.

We can imagine adding more. We could:

  • specify the file name of a .cabal file, eg to target an unpacked package in another directory
  • specify the directory name and look in that directory for a .cabal file
  • specify the file name or url of a .tar.gz package
For example:
cabal list ../some/other/dir/
cabal info http://code.haskell.org/xmonad/xmonad.cabal
cabal install http://haskell.org/cabal/dev/Cabal-1.7.2.tar.gz
cabal install ./demo/
The case cabal info http://code.haskell.org/xmonad/xmonad.cabal is very much like the lscabal program that was uploaded to hackage recently so apparently it is useful.
@bos
Copy link
Contributor Author

bos commented May 24, 2012

(Imported comment by @dcoutts on 2009-03-16)

Added support for:

  • local package directories
  • local cabal files
  • local tarballs
  • remote tarballs
This applies to the install, fetch, info and unpack commands.

Not implemented is alternate targets for the list command, or remote .cabal targets for the info command (opened as #804).

Sun Feb 13 19:41:50 GMT 2011  Duncan Coutts <[email protected]>
  * Add a new module for handling user targets
  This will allow us to increase the range of targets that cabal
  commands can support. The new ones are local directory targets,
  local cabal files, local tarballs and remote tarballs by URL.
  Also a better way of doing the special "world" target.
Sun Feb 13 19:46:27 GMT 2011  Duncan Coutts <[email protected]>
  * Partial rewrite of cabal list and info commands
  The new user target system requires a change in how cabal info works.
  Instead of just giving package names and looking them up in the
  available package index, we can now specify names with versions or
  version constraints which means we want the info to be about that
  version in particular. We now list many installed and available
  versions and mark which ones are preferred or not. Also fix a bug
  for packages that are only installed, not available.
Sun Feb 13 19:50:09 GMT 2011  Duncan Coutts <[email protected]>
  * New interface to the dep resolver that allows modular policy construction
  Allows shorter and clearer code for the various ways the resolver is used.
Sun Feb 13 22:49:55 GMT 2011  Duncan Coutts <[email protected]>
  * Use the new modular dep resolver interface in the various commands
  Also minor tweak to InstallPlan.remove

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

No branches or pull requests

1 participant