1{-# LANGUAGE OverloadedStrings #-}
11import qualified Json.Encode as Json
12import Data.Binary (Binary, get, put)
35merge :: Region -> Region -> Region
36merge (Region start _) (Region _ end) =
44encode :: Region -> Json.Value
45encode (Region start end) =
47 [ ("start", encodePosition start)
48 , ("end", encodePosition end)
52encodePosition :: Position -> Json.Value
53encodePosition (Position line column) =
55 [ ("line", Json.int line)
56 , ("column", Json.int column)
64instance Binary Region where
66 Region <$> get <*> get
68 put (Region start end) =
73instance Binary Position where
75 Position <$> get <*> get
77 put (Position line column) =
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list