| Safe Haskell | None | 
|---|---|
| Language | Haskell2010 | 
System.Process.PagerEditor
Description
Run external pagers ($PAGER, less, more) and editors ($VISUAL,
 $EDITOR, nano, pico, vi).
Synopsis
- pageWriter :: (Handle -> IO ()) -> IO ()
 - pageByteString :: LByteString -> IO ()
 - pageText :: Text -> IO ()
 - pageBuilder :: Builder -> IO ()
 - pageFile :: FilePath -> IO ()
 - pageString :: String -> IO ()
 - data PagerException
 - editFile :: FilePath -> IO ()
 - editReaderWriter :: forall a. String -> (Handle -> IO ()) -> (FilePath -> IO a) -> IO a
 - editByteString :: String -> LByteString -> IO LByteString
 - editString :: String -> String -> IO String
 - data EditorException
 
Pager
pageWriter :: (Handle -> IO ()) -> IO () Source #
Run pager, providing a function that writes to the pager's input.
pageByteString :: LByteString -> IO () Source #
Run pager to display a lazy ByteString.
pageBuilder :: Builder -> IO () Source #
Run pager to display a ByteString-Builder.
pageString :: String -> IO () Source #
Run pager to display a string.
data PagerException Source #
Exception running pager.
Constructors
| PagerNotFound | |
| PagerExitFailure FilePath Int | 
Instances
| Show PagerException Source # | |
Defined in System.Process.PagerEditor Methods showsPrec :: Int -> PagerException -> ShowS # show :: PagerException -> String # showList :: [PagerException] -> ShowS #  | |
| Exception PagerException Source # | |
Defined in System.Process.PagerEditor Methods toException :: PagerException -> SomeException #  | |
Editor
editReaderWriter :: forall a. String -> (Handle -> IO ()) -> (FilePath -> IO a) -> IO a Source #
Run editor, providing functions to write and read the file contents.
editByteString :: String -> LByteString -> IO LByteString Source #
Run editor on a ByteString.
data EditorException Source #
Exception running editor.
Constructors
| EditorNotFound | |
| EditorExitFailure FilePath Int | 
Instances
| Show EditorException Source # | |
Defined in System.Process.PagerEditor Methods showsPrec :: Int -> EditorException -> ShowS # show :: EditorException -> String # showList :: [EditorException] -> ShowS #  | |
| Exception EditorException Source # | |
Defined in System.Process.PagerEditor Methods toException :: EditorException -> SomeException #  | |