dashes in cabal package names
Martin Sjögren
msjogren at gmail.com
Fri Aug 6 08:25:41 EDT 2004
On Fri, 6 Aug 2004 13:15:57 +0100, Simon Marlow <simonmar at microsoft.com> wrote:
> On 06 August 2004 12:53, Martin Sjögren wrote:
>
> >> Dashes in package names? Absolutely. I don't think you need a
> >> non-dash separator between the package name and the version number,
> >> just take the last dash in the package id as the name-version
> >> separator.
> >>
> >> (I really like the <pkgname>-<version> format, probably because it's
> >> so widespread these days).
> >
> > We-ell, there's the issue of the version tags, which use dashes as
> > separator. But if we disallow tags in the package-id, it shouldn't be
> > a problem. foo-bar-0.1.2-bar-foo is harder to understand, though. :)
>
> Grrr. Forgot about the tags. I suggest tags use an underscore separator rather than a dash.
:)
Or a plus as I think Ian suggested at some point: foo-bar-0.1.2+bar+foo.
There is, however, another good reason for not using a dash to
separate name and version. Package names can contain digits. I'm not
sure if they can or should contain dots, but given "foo-3", you don't
know whether it refers to "package foo, version 3" or "package foo-3
without version"... Maybe it's not problematic enough to worry about,
though.
/Martin
More information about the Libraries
mailing list