mirror of
https://github.com/Avi-D-coder/implicit-hie.git
synced 2024-11-22 17:55:51 +03:00
Don't generate trailing spaces
This commit is contained in:
parent
07bd89709f
commit
62e4f18708
23
README.md
23
README.md
@ -16,40 +16,39 @@ cradle:
|
||||
cabal:
|
||||
- path: "indexed-profunctors/src"
|
||||
component: "lib:indexed-profunctors"
|
||||
|
||||
|
||||
- path: "optics-th/src"
|
||||
component: "lib:optics-th"
|
||||
|
||||
|
||||
- path: "optics-th/tests"
|
||||
component: "optics-th:test:optics-th-tests"
|
||||
|
||||
|
||||
- path: "optics-vl/src"
|
||||
component: "lib:optics-vl"
|
||||
|
||||
|
||||
- path: "codegen/./Subtypes.hs"
|
||||
component: "optics-codegen:exe:optics-codegen-subtypes"
|
||||
|
||||
|
||||
- path: "optics-core/src"
|
||||
component: "lib:optics-core"
|
||||
|
||||
|
||||
- path: "optics-sop/src"
|
||||
component: "lib:optics-sop"
|
||||
|
||||
|
||||
- path: "optics-extra/src"
|
||||
component: "lib:optics-extra"
|
||||
|
||||
|
||||
- path: "template-haskell-optics/src"
|
||||
component: "lib:template-haskell-optics"
|
||||
|
||||
|
||||
- path: "optics/src"
|
||||
component: "lib:optics"
|
||||
|
||||
|
||||
- path: "optics/tests"
|
||||
component: "optics:test:optics-tests"
|
||||
|
||||
|
||||
- path: "metametapost/src/Cli.hs"
|
||||
component: "metametapost:exe:metametapost-optics"
|
||||
|
||||
|
||||
```
|
||||
|
||||
|
@ -18,7 +18,14 @@ hieYaml sOrC pkgs =
|
||||
(sOrC <> ":\n" <> indent' pkgs)
|
||||
|
||||
indent' :: String -> String
|
||||
indent' = unlines . map (" " <>) . lines
|
||||
indent' =
|
||||
unlines
|
||||
. map
|
||||
( \l -> case l of
|
||||
"" -> ""
|
||||
_ -> " " <> l
|
||||
)
|
||||
. lines
|
||||
|
||||
cabalComponent :: Name -> Component -> (FilePath, String)
|
||||
cabalComponent n (Comp Lib "" p) = (T.unpack p, T.unpack $ "lib:" <> n)
|
||||
|
Loading…
Reference in New Issue
Block a user