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

Improve cabal init code a bit #6661

Merged
merged 2 commits into from
Apr 6, 2020
Merged

Conversation

phadej
Copy link
Collaborator

@phadej phadej commented Apr 6, 2020

ping @m-renaud

Copy link
Collaborator

@m-renaud m-renaud left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall LGTM, thanks for the cleanups!

cabal-install/Distribution/Client/Init/Command.hs Outdated Show resolved Hide resolved
cabal-install/Distribution/Client/Init/Defaults.hs Outdated Show resolved Hide resolved
@phadej phadej force-pushed the init-improvements branch from c914dde to 0d605da Compare April 6, 2020 15:34
phadej added 2 commits April 6, 2020 18:46
- Always ask for SPDX expression, we can "convert" them to old format
- No default license
- Add cabal-version: 3.0 to the list
- cabal-version is asked using CabalSpecVersion type
- seems to fix what haskell#6619 tries to fix:

```
% /code/shared-haskell/cabal/dist-newstyle/build/x86_64-linux/ghc-8.8.3/cabal-install-3.3.0.0/x/cabal/build/cabal/cabal init -l 'FOO AND BAR'
Cannot parse license: FOO AND BAR
CallStack (from HasCallStack):
  error, called at ./Distribution/ReadE.hs:42:24 in Cabal-3.3.0.0-inplace:Distribution.ReadE
```

an error, but it doesn't loop.
@phadej phadej force-pushed the init-improvements branch from 0d605da to 738a333 Compare April 6, 2020 15:47
Copy link
Collaborator

@m-renaud m-renaud left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG, feel free to merge whenever.

@phadej phadej merged commit c5cfe27 into haskell:master Apr 6, 2020
@phadej phadej deleted the init-improvements branch April 6, 2020 17:39
@phadej phadej mentioned this pull request Jul 10, 2020
@phadej phadej added this to the 3.4.0.0-rc1 milestone Jul 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants