← All packages
relude1.2.0.0
Safe, performant, user-friendly and lightweight Haskell Standard Library
Open the imported Cabal file ↗
- author
- Dmitrii Kovanikov, Veronika Romashkina, Stephen Diehl, Serokell
- bug-reports
- https://github.com/kowainik/relude/issues
- build-type
- Simple
- cabal-version
- 3.0
- category
- Prelude
- copyright
- 2016 Stephen Diehl, 2016-2018 Serokell, 2018-2023 Kowainik
- extra-doc-files
- CHANGELOG.md README.md
- homepage
- https://github.com/kowainik/relude
- license
- MIT
- license-file
- LICENSE
- maintainer
- Kowainik <xrom.xkov@gmail.com>
- name
- relude
- stability
- stable
- synopsis
- Safe, performant, user-friendly and lightweight Haskell Standard Library
- tested-with
- GHC == 8.4.4 GHC == 8.6.5 GHC == 8.8.4 GHC == 8.10.7 GHC == 9.0.2 GHC == 9.2.7 GHC == 9.4.4
- version
- 1.2.0.0
- x-revision
- 1
Show the complete metadata as JSON
{
"schemaVersion": 1,
"name": "relude",
"version": "1.2.0.0",
"cabalVersion": "3.0",
"buildType": "Simple",
"fields": {
"author": [
"Dmitrii Kovanikov, Veronika Romashkina, Stephen Diehl, Serokell"
],
"bug-reports": [
"https://github.com/kowainik/relude/issues"
],
"build-type": [
"Simple"
],
"cabal-version": [
"3.0"
],
"category": [
"Prelude"
],
"copyright": [
"2016 Stephen Diehl, 2016-2018 Serokell, 2018-2023 Kowainik"
],
"description": [
"@__relude__@ is an alternative prelude library. If you find the default\n@Prelude@ unsatisfying, despite its advantages, consider using @relude@\ninstead.\n== Relude goals and design principles\n* __Productivity.__ You can be more productive with a \"non-standard\" standard\nlibrary, and @relude@ helps you with writing safer and more\nefficient code faster.\n* __Total programming__. Usage of [/partial functions/](https://www.reddit.com/r/haskell/comments/5n51u3/why_are_partial_functions_as_in_head_tail_bad/)\ncan lead to unexpected bugs and runtime exceptions in pure\ncode. The types of partial functions lie about their behaviour. And\neven if it is not always possible to rely only on total functions,\n@relude@ strives to encourage best-practices and reduce the\nchances of introducing a bug.\n+---------------------------------+--------------------------------------------+\n| __Partial__ | __Total__ |\n+=================================+============================================+\n| @head :: [a] -> a@ | @head :: NonEmpty a -> a@ |\n+---------------------------------+--------------------------------------------+\n| @tail :: [a] -> [a]@ | @tail :: NonEmpty a -> [a]@ |\n+---------------------------------+--------------------------------------------+\n| @read :: Read a => String -> a@ | @readMaybe :: Read a => String -> Maybe a@ |\n+---------------------------------+--------------------------------------------+\n| @fromJust :: Maybe a -> a@ | @fromMaybe :: a -> Maybe a -> a@ |\n+---------------------------------+--------------------------------------------+\n* __Type-safety__. We use the /\"make invalid states unrepresentable\"/ motto as one\nof our guiding principles. If it is possible, we express this concept through the\ntypes.\n/Example:/ @ whenNotNull :: Applicative f => [a] -> (NonEmpty a -> f ()) -> f () @\n* __Performance.__ We prefer @Text@ over @[String](https://www.reddit.com/r/haskell/comments/29jw0s/whats_wrong_with_string/)@,\nuse space-leaks-free functions (e.g. our custom performant @sum@ and @product@),\nintroduce @\\{\\-\\# INLINE \\#\\-\\}@ and @\\{\\-\\# SPECIALIZE \\#\\-\\}@ pragmas where\nappropriate, and make efficient container types\n(e.g. @Map@, @HashMap@, @Set@) more accessible.\n* __Minimalism__ (low number of dependencies). We do not force users of\n@relude@ to stick to any specific lens or text formatting or logging\nlibrary. Where possible, @relude@ depends only on boot libraries.\nThe [Dependency graph](https://raw.githubusercontent.com/kowainik/relude/main/relude-dependency-graph.png)\nof @relude@ can give you a clearer picture.\n* __Convenience__. Despite minimalism, we want to bring commonly used\ntypes and functions into scope, and make available functions easier\nto use. Some examples of conveniences:\n1. No need to add @containers@, @unordered-containers@, @text@\nand @bytestring@ to dependencies in your @.cabal@ file to\nuse the main API of these libraries\n2. No need to import types like @NonEmpty@, @Text@, @Set@, @Reader[T]@, @MVar@, @STM@\n3. Functions like @liftIO@, @fromMaybe@, @sortWith@ are available by default as well\n4. @IO@ actions are lifted to @MonadIO@\n* __Excellent documentation.__\n1. Tutorial\n2. Migration guide from @Prelude@\n3. Haddock for every function with examples tested by\n[doctest](http://hackage.haskell.org/package/doctest).\n4. Documentation regarding [internal module structure](http://hackage.haskell.org/package/relude/docs/Relude.html)\n5. @relude@-specific [HLint](http://hackage.haskell.org/package/hlint) rules: @[.hlint.yaml](https://github.com/kowainik/relude/blob/main/.hlint.yaml)@\n* __User-friendliness.__ Anyone should be able to quickly migrate to @relude@. Only\nsome basic familiarity with the common libraries like @text@ and @containers@\nshould be enough (but not necessary).\n* __Exploration.__ We have space to experiment with new ideas and proposals\nwithout introducing breaking changes. @relude@ uses the approach with\n@Extra.*@ modules which are not exported by default. The chosen approach makes it quite\neasy for us to provide new functionality without breaking anything and let\nthe users decide to use it or not."
],
"extra-doc-files": [
"CHANGELOG.md\nREADME.md"
],
"homepage": [
"https://github.com/kowainik/relude"
],
"license": [
"MIT"
],
"license-file": [
"LICENSE"
],
"maintainer": [
"Kowainik <xrom.xkov@gmail.com>"
],
"name": [
"relude"
],
"stability": [
"stable"
],
"synopsis": [
"Safe, performant, user-friendly and lightweight Haskell Standard Library"
],
"tested-with": [
"GHC == 8.4.4\nGHC == 8.6.5\nGHC == 8.8.4\nGHC == 8.10.7\nGHC == 9.0.2\nGHC == 9.2.7\nGHC == 9.4.4"
],
"version": [
"1.2.0.0"
],
"x-revision": [
"1"
]
},
"components": [
{
"kind": "library",
"name": "main",
"tree": {
"data": {
"buildable": null,
"exposedModules": [
"Relude",
"Relude.Applicative",
"Relude.Base",
"Relude.Bool",
"Relude.Bool.Guard",
"Relude.Bool.Reexport",
"Relude.Container",
"Relude.Container.One",
"Relude.Container.Reexport",
"Relude.Debug",
"Relude.DeepSeq",
"Relude.Enum",
"Relude.Exception",
"Relude.File",
"Relude.Foldable",
"Relude.Foldable.Fold",
"Relude.Foldable.Reexport",
"Relude.Function",
"Relude.Functor",
"Relude.Functor.Fmap",
"Relude.Functor.Reexport",
"Relude.Lifted",
"Relude.Lifted.Concurrent",
"Relude.Lifted.Exit",
"Relude.Lifted.File",
"Relude.Lifted.IORef",
"Relude.Lifted.Terminal",
"Relude.Lifted.Handle",
"Relude.Lifted.Env",
"Relude.List",
"Relude.List.NonEmpty",
"Relude.List.Reexport",
"Relude.Monad",
"Relude.Monad.Either",
"Relude.Monad.Maybe",
"Relude.Monad.Reexport",
"Relude.Monad.Trans",
"Relude.Monoid",
"Relude.Nub",
"Relude.Numeric",
"Relude.Print",
"Relude.String",
"Relude.String.Conversion",
"Relude.String.Reexport",
"Relude.Extra",
"Relude.Extra.Bifunctor",
"Relude.Extra.CallStack",
"Relude.Extra.Enum",
"Relude.Extra.Foldable",
"Relude.Extra.Foldable1",
"Relude.Extra.Group",
"Relude.Extra.Lens",
"Relude.Extra.Map",
"Relude.Extra.Newtype",
"Relude.Extra.Tuple",
"Relude.Extra.Type",
"Relude.Unsafe"
],
"otherModules": [],
"dependencies": [
{
"package": "base",
"range": ">=4.11 && <4.19",
"libraries": [
"main"
]
},
{
"package": "bytestring",
"range": ">=0.10 && <0.13",
"libraries": [
"main"
]
},
{
"package": "containers",
"range": ">=0.5.10 && <0.7",
"libraries": [
"main"
]
},
{
"package": "deepseq",
"range": "^>=1.4 || ^>=1.5",
"libraries": [
"main"
]
},
{
"package": "ghc-prim",
"range": ">=0.5.0.0 && <0.11",
"libraries": [
"main"
]
},
{
"package": "hashable",
"range": ">=1.2 && <1.5",
"libraries": [
"main"
]
},
{
"package": "mtl",
"range": ">=2.2 && <2.4",
"libraries": [
"main"
]
},
{
"package": "stm",
"range": ">=2.4 && <2.6",
"libraries": [
"main"
]
},
{
"package": "text",
"range": ">=1.2 && <2.1",
"libraries": [
"main"
]
},
{
"package": "transformers",
"range": ">=0.5 && <0.7",
"libraries": [
"main"
]
},
{
"package": "unordered-containers",
"range": ">=0.2.7 && <0.3",
"libraries": [
"main"
]
}
],
"fields": {
"reexported-modules": [
", Data.IntMap.Lazy\n, Data.IntMap.Strict\n, Data.IntSet\n, Data.Map.Lazy\n, Data.Map.Strict\n, Data.Set\n, Data.Sequence\n, Data.Tree\n, Data.HashMap.Lazy\n, Data.HashMap.Strict\n, Data.HashSet\n, Data.Text\n, Data.Text.IO\n, Data.Text.Lazy\n, Data.Text.Lazy.IO\n, Data.Text.Read\n, Data.ByteString\n, Data.ByteString.Builder\n, Data.ByteString.Lazy\n, Data.ByteString.Short"
]
}
},
"branches": [
{
"condition": {
"compiler": "ghc",
"range": ">=8.4"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=8.8"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=8.10"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.0"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.2"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.4"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
}
]
}
},
{
"kind": "test-suite",
"name": "relude-test",
"tree": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [
"Test.Relude.Gen",
"Test.Relude.Container.One",
"Test.Relude.Property"
],
"dependencies": [
{
"package": "base",
"range": "-any",
"libraries": [
"main"
]
},
{
"package": "relude",
"range": "-any",
"libraries": [
"main"
]
},
{
"package": "bytestring",
"range": "-any",
"libraries": [
"main"
]
},
{
"package": "containers",
"range": "-any",
"libraries": [
"main"
]
},
{
"package": "text",
"range": "-any",
"libraries": [
"main"
]
},
{
"package": "hedgehog",
"range": ">=1.0 && <1.4",
"libraries": [
"main"
]
}
],
"fields": {
"type": [
"exitcode-stdio-1.0"
]
}
},
"branches": [
{
"condition": {
"compiler": "ghc",
"range": ">=8.4"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=8.8"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=8.10"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.0"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.2"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.4"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
}
]
}
},
{
"kind": "test-suite",
"name": "relude-doctest",
"tree": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [
{
"package": "relude",
"range": "-any",
"libraries": [
"main"
]
},
{
"package": "doctest",
"range": ">=0.20 && <0.22",
"libraries": [
"main"
]
},
{
"package": "Glob",
"range": "-any",
"libraries": [
"main"
]
}
],
"fields": {
"type": [
"exitcode-stdio-1.0"
]
}
},
"branches": [
{
"condition": {
"compiler": "ghc",
"range": ">=8.4"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=8.8"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=8.10"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.0"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.2"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.4"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
}
]
}
},
{
"kind": "benchmark",
"name": "relude-benchmark",
"tree": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [
{
"package": "base",
"range": "-any",
"libraries": [
"main"
]
},
{
"package": "relude",
"range": "-any",
"libraries": [
"main"
]
},
{
"package": "tasty-bench",
"range": "-any",
"libraries": [
"main"
]
},
{
"package": "unordered-containers",
"range": "-any",
"libraries": [
"main"
]
}
],
"fields": {
"type": [
"exitcode-stdio-1.0"
]
}
},
"branches": [
{
"condition": {
"compiler": "ghc",
"range": ">=8.4"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=8.8"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=8.10"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.0"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.2"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
},
{
"condition": {
"compiler": "ghc",
"range": ">=9.4"
},
"then": {
"data": {
"buildable": null,
"exposedModules": [],
"otherModules": [],
"dependencies": [],
"fields": {}
},
"branches": []
},
"else": null
}
]
}
}
],
"setupDependencies": [],
"flags": [],
"sourceRepositories": [
{
"kind": "head",
"fields": {
"location": [
"git@github.com:kowainik/relude.git"
],
"type": [
"git"
]
}
}
],
"warnings": [],
"sourceUrl": "https://hackage.haskell.org/package/relude-1.2.0.0/relude.cabal",
"sha256": "f99bcd6dfd240ad0a13a0307464a6c20a229e8456da7a028377b4f0995c575ed",
"importedAt": "2026-10-29T10:03:00.536Z",
"dependencies": [
{
"package": "base",
"range": ">=4.11 && <4.19",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "bytestring",
"range": ">=0.10 && <0.13",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "containers",
"range": ">=0.5.10 && <0.7",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "deepseq",
"range": "^>=1.4 || ^>=1.5",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "ghc-prim",
"range": ">=0.5.0.0 && <0.11",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "hashable",
"range": ">=1.2 && <1.5",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "mtl",
"range": ">=2.2 && <2.4",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "stm",
"range": ">=2.4 && <2.6",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "text",
"range": ">=1.2 && <2.1",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "transformers",
"range": ">=0.5 && <0.7",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "unordered-containers",
"range": ">=0.2.7 && <0.3",
"libraries": [
"main"
],
"component": "library:main",
"conditions": []
},
{
"package": "base",
"range": "-any",
"libraries": [
"main"
],
"component": "test-suite:relude-test",
"conditions": []
},
{
"package": "relude",
"range": "-any",
"libraries": [
"main"
],
"component": "test-suite:relude-test",
"conditions": []
},
{
"package": "bytestring",
"range": "-any",
"libraries": [
"main"
],
"component": "test-suite:relude-test",
"conditions": []
},
{
"package": "containers",
"range": "-any",
"libraries": [
"main"
],
"component": "test-suite:relude-test",
"conditions": []
},
{
"package": "text",
"range": "-any",
"libraries": [
"main"
],
"component": "test-suite:relude-test",
"conditions": []
},
{
"package": "hedgehog",
"range": ">=1.0 && <1.4",
"libraries": [
"main"
],
"component": "test-suite:relude-test",
"conditions": []
},
{
"package": "relude",
"range": "-any",
"libraries": [
"main"
],
"component": "test-suite:relude-doctest",
"conditions": []
},
{
"package": "doctest",
"range": ">=0.20 && <0.22",
"libraries": [
"main"
],
"component": "test-suite:relude-doctest",
"conditions": []
},
{
"package": "Glob",
"range": "-any",
"libraries": [
"main"
],
"component": "test-suite:relude-doctest",
"conditions": []
},
{
"package": "base",
"range": "-any",
"libraries": [
"main"
],
"component": "benchmark:relude-benchmark",
"conditions": []
},
{
"package": "relude",
"range": "-any",
"libraries": [
"main"
],
"component": "benchmark:relude-benchmark",
"conditions": []
},
{
"package": "tasty-bench",
"range": "-any",
"libraries": [
"main"
],
"component": "benchmark:relude-benchmark",
"conditions": []
},
{
"package": "unordered-containers",
"range": "-any",
"libraries": [
"main"
],
"component": "benchmark:relude-benchmark",
"conditions": []
}
],
"exposedModules": [
"Relude",
"Relude.Applicative",
"Relude.Base",
"Relude.Bool",
"Relude.Bool.Guard",
"Relude.Bool.Reexport",
"Relude.Container",
"Relude.Container.One",
"Relude.Container.Reexport",
"Relude.Debug",
"Relude.DeepSeq",
"Relude.Enum",
"Relude.Exception",
"Relude.File",
"Relude.Foldable",
"Relude.Foldable.Fold",
"Relude.Foldable.Reexport",
"Relude.Function",
"Relude.Functor",
"Relude.Functor.Fmap",
"Relude.Functor.Reexport",
"Relude.Lifted",
"Relude.Lifted.Concurrent",
"Relude.Lifted.Exit",
"Relude.Lifted.File",
"Relude.Lifted.IORef",
"Relude.Lifted.Terminal",
"Relude.Lifted.Handle",
"Relude.Lifted.Env",
"Relude.List",
"Relude.List.NonEmpty",
"Relude.List.Reexport",
"Relude.Monad",
"Relude.Monad.Either",
"Relude.Monad.Maybe",
"Relude.Monad.Reexport",
"Relude.Monad.Trans",
"Relude.Monoid",
"Relude.Nub",
"Relude.Numeric",
"Relude.Print",
"Relude.String",
"Relude.String.Conversion",
"Relude.String.Reexport",
"Relude.Extra",
"Relude.Extra.Bifunctor",
"Relude.Extra.CallStack",
"Relude.Extra.Enum",
"Relude.Extra.Foldable",
"Relude.Extra.Foldable1",
"Relude.Extra.Group",
"Relude.Extra.Lens",
"Relude.Extra.Map",
"Relude.Extra.Newtype",
"Relude.Extra.Tuple",
"Relude.Extra.Type",
"Relude.Unsafe"
],
"documents": {
"readme": {
"status": "available",
"sha256": "311743341bb10af439d6ecc720b29d2ecb0c7d41ebcbb74bf8e2357db28a1b1a",
"error": null,
"checkedAt": "2026-10-29T10:03:01.796Z"
},
"changelog": {
"status": "available",
"sha256": "dd519e8ce4ea0cd41781f24e39e49794d3c0ae1d5ec526af2491df68aa591307",
"error": null,
"checkedAt": "2026-10-29T10:03:01.809Z"
}
},
"documentation": null,
"versions": [
{
"version": "1.2.0.0",
"imported_at": "2026-10-29T10:03:00.536Z"
}
]
}