Text wrap in Haskell code
This adds two functions in Utils.hs: 'wrap' and 'trim' along with some simple tests. 'wrap' is used in Common.hs for wrapping command descriptions to a fixed line length, e.g. useful for the "--help" option. Signed-off-by:Yiannis Tsiouris <gtsiour@softlab.ntua.gr> Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
Showing
- src/Ganeti/Common.hs 8 additions, 3 deletionssrc/Ganeti/Common.hs
- src/Ganeti/Utils.hs 33 additions, 0 deletionssrc/Ganeti/Utils.hs
- test/hs/Test/Ganeti/Common.hs 37 additions, 1 deletiontest/hs/Test/Ganeti/Common.hs
- test/hs/Test/Ganeti/Utils.hs 18 additions, 0 deletionstest/hs/Test/Ganeti/Utils.hs
Loading
Please register or sign in to comment