> module List
>        (list)
>        where

> import Data.String.Utils
> import Rogerlins (rins, db)

> isli :: [Char] -> Bool
> isli l = (length l >=2)                      &&
>          (head (dropWhile (== ' ') l) == '-') &&
>          ((dropWhile (== ' ') l)!!1 == ' ')

> dropboth :: String -> String 
> dropboth = (dropWhile (== ' ')) .
>            (dropWhile (== '-')) .
>            (dropWhile (== ' ')) 

> item :: [Char] -> [Char]
> item l | isli l = "<item>"     ++
>                    dropboth l  ++
>                   "</item>"
>        | otherwise = l

> toptail :: [String] -> [String]
> toptail = rins (isli) "<list>" "</list>"

> empty :: String -> Bool
> empty x = strip x == ""

> list :: String -> String
> list = unlines . (map item) . toptail . (db isli empty) . lines

> a = "\n- item 1\n\n-item2\n\nThis that"


