mirror of
https://github.com/github/semantic.git
synced 2024-12-22 22:31:36 +03:00
17 lines
467 B
Haskell
17 lines
467 B
Haskell
module Renderer where
|
|
|
|
import Prologue
|
|
import Data.Functor.Both
|
|
import Diff
|
|
import Source
|
|
|
|
-- | A function that will render a diff, given the two source blobs.
|
|
type Renderer annotation = Both SourceBlob -> Diff Text annotation -> Text
|
|
|
|
data DiffArguments = DiffArguments { format :: Format, output :: Maybe FilePath, outputPath :: FilePath }
|
|
deriving (Show)
|
|
|
|
-- | The available types of diff rendering.
|
|
data Format = Split | Patch | JSON | Summary
|
|
deriving (Show)
|