packages feed

hsinstall 2.9 → 2.10

raw patch · 8 files changed

+55/−48 lines, 8 filesdep +optparse-applicative-dexdep +textdep −optparse-applicativedep −prettyprinterdep ~Cabaldep ~filepathdep ~hsinstallPVP ok

version bump matches the API change (PVP)

Dependencies added: optparse-applicative-dex, text

Dependencies removed: optparse-applicative, prettyprinter

Dependency ranges changed: Cabal, filepath, hsinstall

API changes (from Hackage documentation)

Files

CHANGELOG.md view
@@ -1,3 +1,13 @@+2.10 (2025-09-16)++  * Fixed cabal bounds+  * Fixes for compatibility with Cabal-syntax-3.14.0.0+  * Switched to optparse-applicative-dex library+  * No longer need to explicitly derive Typeable+  * Added ImportQualifiedPost to cabal file+  * Changed URLs from github to codeberg++ 2.9 (2025-07-30)    * Moved CHANGELOG.md to extra-doc-files stanza
README.md view
@@ -89,17 +89,17 @@  In order to locate data files at runtime, including resources, the hsinstall project includes a library to construct the share path relative to the-executable. See [this source code](https://github.com/dino-/hsinstall/blob/master/src/lib/HSInstall/Paths.hs)+executable. See [this source code](https://codeberg.org/dinofp/hsinstall/src/branch/main/src/lib/HSInstall/Paths.hs) for help with integrating this into your app.   ## Development -Browse [the source](https://github.com/dino-/hsinstall)+Browse [the source](https://codeberg.org/dinofp/hsinstall)  Get source with git and build -    $ git clone https://github.com/dino-/hsinstall.git+    $ git clone https://codeberg.org/dinofp/hsinstall.git     $ cd hsinstall     $ stack build     $ stack haddock --no-haddock-deps hsinstall
hsinstall.cabal view
@@ -1,15 +1,15 @@ cabal-version: 2.2  name: hsinstall-version: 2.9+version: 2.10 synopsis: Install Haskell software description: This is a tool for deploying software projects into directory   structures suitable for installation on a system. It builds upon the `stack   install` command and adds more features. It's also a tool for easier AppImage   creation. category: Utility-homepage: https://github.com/dino-/hsinstall#readme-bug-reports: https://github.com/dino-/hsinstall/issues+homepage: https://codeberg.org/dinofp/hsinstall+bug-reports: https://codeberg.org/dinofp/hsinstall/issues author: Dino Morelli maintainer: Dino Morelli <dino@ui3.info> copyright: 2016 Dino Morelli@@ -30,7 +30,7 @@  source-repository head   type: git-  location: https://github.com/dino-/hsinstall+  location: https://codeberg.org/dinofp/hsinstall  common lang   default-language: Haskell2010@@ -45,6 +45,7 @@     FlexibleContexts     FlexibleInstances     GeneralizedNewtypeDeriving+    ImportQualifiedPost     InstanceSigs     KindSignatures     LambdaCase@@ -60,6 +61,7 @@     -fwarn-tabs     -Wall     -Wcompat+    -Wderiving-typeable     -Wincomplete-record-updates     -Wincomplete-uni-patterns     -Wpartial-fields@@ -67,7 +69,7 @@   build-depends:       base >=3 && <5     , directory >=1.3.8.1 && <1.4-    , filepath >=1.4.100.4 && <1.5+    , filepath >=1.4.100.4 && < 1.6   other-modules:     Paths_hsinstall   autogen-modules:@@ -98,13 +100,13 @@   hs-source-dirs:       src/app   build-depends:-      Cabal >=3.10.1.0 && <4+      Cabal >=3.14.0.0 && <4     , exceptions >=0.10.7 && <1     , formatting >=7.2.0 && <8     , heredoc >=0.2.0.0 && <0.3-    , hsinstall <3-    , optparse-applicative >=0.18.1.0 && <0.19-    , prettyprinter >=1.7.1 && <2+    , hsinstall+    , optparse-applicative-dex >=1.0.1 && <1.2     , process >=1.6.17.0 && <2     , safe-exceptions >=0.1.7.4 && <0.2+    , text >=2.0.2 && <2.3     , transformers >=0.6.1.0 && <0.7
src/app/HSInstall/DeploymentInfo.hs view
@@ -28,6 +28,7 @@ import Distribution.Simple.PackageDescription (readGenericPackageDescription) import Distribution.Types.PackageName (unPackageName) import Distribution.Types.Version (Version)+import Distribution.Utils.Path (makeSymbolicPath) import Distribution.Verbosity (normal) import System.Directory (getDirectoryContents) import System.FilePath ((</>), (<.>))@@ -59,9 +60,14 @@   }  +-- This tool is designed to only be run in the top-level directory of a Haskell+-- package that's being packaged for deployment.+cwd :: FilePath+cwd = "."++ locateCabalFile :: IO (Maybe FilePath)-locateCabalFile = find (isSuffixOf ".cabal")-    <$> getDirectoryContents "."+locateCabalFile = find (isSuffixOf ".cabal") <$> getDirectoryContents cwd   constructDeploymentInfo :: BuildTool -> Options -> IO DeploymentInfo@@ -69,9 +75,10 @@   mbCabalFile <- runMaybeT     $   MaybeT locateCabalFile     <|> MaybeT (makeCabal buildTool >> locateCabalFile)+  let path = Just $ makeSymbolicPath cwd   maybe (throwM NoCabalFiles)     (fmap (constructDeploymentInfo' opts . package . packageDescription)-      . readGenericPackageDescription normal) mbCabalFile+      . readGenericPackageDescription normal path . makeSymbolicPath) mbCabalFile   constructDeploymentInfo' :: Options -> PackageId -> DeploymentInfo
src/app/HSInstall/Except.hs view
@@ -8,8 +8,8 @@   )   where -import Control.Exception.Safe (Exception, Handler (..), Typeable, catches,-  catchIO, throwM)+import Control.Exception.Safe (Exception, Handler (..), catches, catchIO,+  throwM) import Control.Monad.Catch (MonadCatch) import GHC.IO.Exception (IOException) import System.Exit (die)@@ -17,7 +17,6 @@  data HSInstallException   = NoCabalFiles-  deriving Typeable  instance Show HSInstallException where   show NoCabalFiles = "no cabal files were found in .  We tried to run `hpack` and/or `stack query` and still don't see a cabal file. Is this directory really a Haskell project?"
src/app/HSInstall/Opts.hs view
@@ -10,13 +10,12 @@   )   where +import Data.Text.Lazy (Text) import Data.Version (showVersion)-import Formatting ((%+), format, formatToString)+import Formatting ((%+), format) import Formatting.ShortFormatters (s)-import Options.Applicative+import Options.Applicative.Dex import Paths_hsinstall (version)-import Prettyprinter (pretty)-import System.Environment (getProgName) import Text.Heredoc (here)  import HSInstall.Common (ExeFile (..), Signing (SigningKeyId, NoSignature))@@ -39,6 +38,12 @@   }  +parseOpts :: IO Options+parseOpts = parseOpts' parser+  "Pack a haskell project into a deployable directory structure"+  footerContent version++ {- HLINT ignore "Functor law" -} parser :: Parser Options parser = Options@@ -76,26 +81,8 @@         )  -versionHelper :: String -> Parser (a -> a)-versionHelper progName =-  infoOption (formatToString (s %+ s) progName (showVersion version)) $ mconcat-  [ long "version"-  , help "Show version information"-  , hidden-  ]---parseOpts :: IO Options-parseOpts = do-  pn <- getProgName-  execParser $ info (parser <**> helper <**> versionHelper pn)-    (  header (formatToString (s %+ "- Pack a haskell project into a deployable directory structure") pn)-    <> footer'-    )---footer' :: InfoMod a-footer' = footerDoc . Just . pretty $ format content (showVersion version)+footerContent :: Text+footerContent = format content (showVersion version)     where content = [here|OVERVIEW  hsinstall is a tool for installing a Haskell software project into a directory structure for deployment. It builds upon the `stack install` and `cabal install` commands and adds these features:@@ -166,6 +153,6 @@               apps/                 <EXE>.svg  <-- Will be generated by first-time AppImage creation attempt -In order to locate data files at runtime, including resources, the hsinstall project includes a library to construct the share path relative to the executable. See this source code for help with integrating this into your app: https://github.com/dino-/hsinstall/blob/master/src/lib/HSInstall/Resources.hs+In order to locate data files at runtime, including resources, the hsinstall project includes a library to construct the share path relative to the executable. See this source code for help with integrating this into your app: https://codeberg.org/dinofp/hsinstall/src/branch/main/src/lib/HSInstall/Paths.hs  Version|] %+ s %+ " Dino Morelli <dino@ui3.info>"
stack.yaml view
@@ -1,4 +1,6 @@-snapshot: lts-22.6+snapshot: nightly-2025-09-12  packages: - '.'++extra-deps: []
stack.yaml.lock view
@@ -6,7 +6,7 @@ packages: [] snapshots: - completed:-    sha256: 1b4c2669e26fa828451830ed4725e4d406acc25a1fa24fcc039465dd13d7a575-    size: 714100-    url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/22/6.yaml-  original: lts-22.6+    sha256: 685183d0914eab54c30fb9fc99b356a12b1775d6314dca5f80c6938d74b91fdc+    size: 692467+    url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/nightly/2025/9/12.yaml+  original: nightly-2025-09-12