mem-info 0.4.0.0 → 0.4.1.0
raw patch · 3 files changed
+20/−4 lines, 3 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- ChangeLog.md +6/−2
- mem-info.cabal +3/−1
- src/System/MemInfo/Choices.hs +11/−1
ChangeLog.md view
@@ -2,6 +2,10 @@ `mem-info` uses [PVP Versioning][1]. +## 0.4.1.0 -- 2025-03-03++- Add a --version flag that prints the version and exits+ ## 0.4.0.0 -- 2025-03-02 - Add option --proc-root@@ -12,7 +16,7 @@ - Breaking changes: -* [ProcNamer][2] takes an additional argument that specifies the proc filesystem root+ - [ProcNamer][2] takes an additional argument that specifies the proc filesystem root ## 0.3.1.0 -- 2025-02-18@@ -55,4 +59,4 @@ * Initial version. [1]: https://pvp.haskell.org-[2]: https://hackage.haskell.org/package/mem-info-0.3.1.0/docs/System-MemInfo.html#t:ProcNamer+[2]: https://hackage.haskell.org/package/mem-info/docs/System-MemInfo.html#t:ProcNamer
mem-info.cabal view
@@ -1,6 +1,6 @@ cabal-version: 3.0 name: mem-info-version: 0.4.0.0+version: 0.4.1.0 synopsis: Print the core memory usage of programs description: A utility to accurately report the core memory usage of programs.@@ -33,6 +33,7 @@ location: https://github.com/adetokunbo/mem-info.git library+ autogen-modules: Paths_mem_info exposed-modules: System.MemInfo System.MemInfo.Choices@@ -40,6 +41,7 @@ System.MemInfo.Proc System.MemInfo.SysInfo other-modules:+ Paths_mem_info System.MemInfo.Prelude hs-source-dirs: src
src/System/MemInfo/Choices.hs view
@@ -28,6 +28,7 @@ import Data.Fixed (Deci) import qualified Data.Text as Text import Data.Text.Read (Reader, rational)+import Data.Version (showVersion) import GHC.Generics (Generic) import Options.Applicative ( Parser,@@ -38,6 +39,7 @@ help, helper, info,+ infoOption, long, metavar, option,@@ -50,6 +52,7 @@ value, ) import Options.Applicative.NonEmpty (some1)+import Paths_mem_info (version) import System.MemInfo.Prelude @@ -77,7 +80,14 @@ -- | Specifies a command line that when parsed will provide 'Choices' cmdInfo :: ParserInfo Choices-cmdInfo = info (helper <*> parseChoices) mempty+cmdInfo = info (versionOption <*> helper <*> parseChoices) mempty+++versionOption :: Parser (a -> a)+versionOption =+ infoOption+ ("printmem version " ++ showVersion version)+ (long "version" <> help "Show the version and exit") parseChoices :: Parser Choices