packages feed

cabal2spec 2.2.2.1 → 2.3

raw patch · 3 files changed

+13/−11 lines, 3 filesdep ~CabalPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: Cabal

API changes (from Hackage documentation)

Files

cabal2spec.cabal view
@@ -1,5 +1,5 @@ name:               cabal2spec-version:            2.2.2.1+version:            2.3 synopsis:           Convert Cabal files into rpm spec files description:        Convert                     Cabal files into a@@ -14,7 +14,7 @@ license-file:       LICENSE author:             Peter Simons, Bryan O'Sullivan, Jens Petersen maintainer:         simons@cryp.to-tested-with:        GHC == 8.0.2, GHC == 8.2.2, GHC == 8.4.4, GHC == 8.6.3+tested-with:        GHC == 8.0.2, GHC == 8.2.2, GHC == 8.4.4, GHC == 8.6.5, GHC == 8.8.1 category:           Distribution homepage:           https://github.com/peti/cabal2spec build-type:         Simple@@ -30,7 +30,7 @@ library   exposed-modules:    Cabal2Spec   hs-source-dirs:     src-  build-depends:      base < 5, Cabal > 2.2, filepath, time >= 1.5+  build-depends:      base < 5, Cabal == 3.0.*, filepath, time >= 1.5   default-language:   Haskell2010   default-extensions: MonadFailDesugaring   ghc-options:        -Wall -Wcompat -Wincomplete-uni-patterns -Wincomplete-record-updates
cabal2spec/Main.hs view
@@ -1,3 +1,4 @@+{-# LANGUAGE LambdaCase #-} {-# LANGUAGE RecordWildCards #-}  module Main ( main ) where@@ -7,6 +8,7 @@  import Data.Maybe import Data.Monoid+import Data.Version import Distribution.Compiler import Distribution.PackageDescription hiding ( options ) import Distribution.System@@ -36,16 +38,16 @@   <*> strArgument (metavar "CABAL-FILE")  parseFlag :: ReadM (FlagName,Bool)-parseFlag = maybeReader $ \s -> case s of-                                  []      -> Nothing-                                  ('-':f) -> Just (mkFlagName f, False)-                                  ('+':f) -> Just (mkFlagName f, True)-                                  f       -> Just (mkFlagName f, True)+parseFlag = maybeReader $ \case+                            []      -> Nothing+                            ('-':f) -> Just (mkFlagName f, False)+                            ('+':f) -> Just (mkFlagName f, True)+                            f       -> Just (mkFlagName f, True)  pinfo :: ParserInfo Options pinfo = info         (   helper-        <*> infoOption ("cabal2spec " ++ display version) (long "version" <> help "Show version number")+        <*> infoOption ("cabal2spec " ++ showVersion version) (long "version" <> help "Show version number")         <*> options         )         (  fullDesc
src/Cabal2Spec.hs view
@@ -372,7 +372,7 @@ excludedPkgs pkgDesc = flip notElem (subLibs ++ ["Cabal", "base", "ghc-prim", "integer-gmp"])   where     subLibs :: [String]-    subLibs = [ unUnqualComponentName ln | l <- subLibraries pkgDesc, Just ln <- [libName l] ]+    subLibs = [ unUnqualComponentName ln | l <- subLibraries pkgDesc, LSubLibName ln <- [libName l] ]  -- returns list of deps and whether package is self-dependent buildDependencies :: PackageDescription -> String -> ([String], Bool)@@ -388,7 +388,7 @@   depName :: a -> String  instance IsDependency Dependency where-  depName (Dependency n _) = unPackageName n+  depName (Dependency n _ _) = unPackageName n  instance IsDependency PkgconfigDependency where   depName (PkgconfigDependency n _) = unPkgconfigName n