1{-# OPTIONS_GHC -Wno-orphans #-}
3module Data.Tasks.StatusUpdate
9import Control.AppRequestable
11import Data.Aeson hiding (Success)
12import qualified Data.Text as T
18 { owner :: Name Owner,
19 repoName :: Name Repo,
23 deriving (Eq, Show, Generic, ToJSON, FromJSON)
25instance FromJSON NewStatus where
26 parseJSON = withObject "NewStatus" $ \v ->
29 <*> v .:? "target_url"
30 <*> v .:? "description"
33instance Task StatusUpdate "update-commit-ci-status" where
34 type TaskMonad StatusUpdate m = (AppRequestable m)
36 performTask StatusUpdate {..} = do
37 response <- appRequest $ createStatusR owner repoName sha status
39 Left err -> logError (T.pack $ show err) >> return Failure
40 Right st -> logDebug (T.pack $ show st) >> return Success
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