listIface clo f                   = do (ifc,f) <- decodeModule clo f
                                       --writeAPI f ifc
                                       let modul = rmSuffix ".ti" f
                                           htmlfile = modul++".html"
                                       res <- checkUpToDate f htmlfile
                                       if not res then do
                                          writeAPI modul ifc
                                          system (Config.pager clo ++" " ++ htmlfile)
                                        else system (Config.pager clo ++" " ++ htmlfile)
  where checkUpToDate tiFile htmlFile = do html_exists <- Directory.doesFileExist htmlFile
                                           if not html_exists then
                                              return False
                                            else do
                                              ti_time  <- Directory.getModificationTime tiFile
                                              html_time  <- Directory.getModificationTime htmlFile
                                              return (ti_time <= html_time)
listIface clo f                   = do (ifc,f) <- decodeModule clo f
                                       --writeAPI f ifc
                                       let modul = rmSuffix ".ti" f
                                           htmlfile = modul++".html"
                                       res <- checkUpToDate f htmlfile
                                       if not res then do
                                          writeAPI modul ifc
                                          system (Config.pager clo ++" " ++ htmlfile)
                                        else system (Config.pager clo ++" " ++ htmlfile)
  where checkUpToDate tiFile htmlFile = do html_exists <- Directory.doesFileExist htmlFile
                                           if not html_exists then
                                              return False
                                            else do
                                              ti_time  <- Directory.getModificationTime tiFile
                                              html_time  <- Directory.getModificationTime htmlFile
                                              return (ti_time <= html_time)
listIface clo f                   = do (ifc,f) <- decodeModule clo f
                                       --writeAPI f ifc
                                       let modul = rmSuffix ".ti" f
                                           htmlfile = modul++".html"
                                       res <- checkUpToDate f htmlfile
                                       if not res then do
                                          writeAPI modul ifc
                                          system (Config.pager clo ++" " ++ htmlfile)
                                        else system (Config.pager clo ++" " ++ htmlfile)
  where checkUpToDate tiFile htmlFile = do html_exists <- Directory.doesFileExist htmlFile
                                           if not html_exists then
                                              return False
                                            else do
                                              ti_time  <- Directory.getModificationTime tiFile
                                              html_time  <- Directory.getModificationTime htmlFile
                                              return (ti_time <= html_time)