<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
</head>
<body class='hmmessage'>
I need the trick to get from <BR>
<FONT face="Courier New">ByteString -> [GHC.Word.Word8]</FONT><BR>
and Hayoo is not helping.<BR>
<BR>
Super simple I expected. I haven't even tried to compile it yet.<BR>
I am just trying to read in the bytes and encode with base64:<BR>
<BR>
<FONT face="Courier New">import Codec.Binary.Base64<BR>import Data.ByteString<BR>import System.Directory<BR>import System.Environment</FONT><BR>
<FONT face="Courier New">main :: do<BR> args <- getArgs<BR> bFileExist <- System.Directory.doesFileExist (args !! 0)<BR> let bytedata = --ByteString -> [GHC.Word.Word8]<BR> if bFileExist then putStrLn $ Codec.Binary.Base64.encode bytedata<BR> else putStrlLn ("File does not exist: " ++ (args !! 0))<BR> return ()</FONT><BR>                                            </body>
</html>