mirror of
https://github.com/unisonweb/unison.git
synced 2024-09-11 10:35:57 +03:00
stub out client side of share api
This commit is contained in:
parent
003ccb0284
commit
dd234993fe
@ -78,6 +78,7 @@ dependencies:
|
||||
- unison-prelude
|
||||
- unison-pretty-printer
|
||||
- unison-share-api
|
||||
- unison-share-projects-api
|
||||
- unison-sqlite
|
||||
- unison-syntax
|
||||
- unison-util-base32hex
|
||||
|
24
unison-cli/src/Unison/Cli/Share/Projects.hs
Normal file
24
unison-cli/src/Unison/Cli/Share/Projects.hs
Normal file
@ -0,0 +1,24 @@
|
||||
-- | Share API calls related to projects.
|
||||
module Unison.Cli.Share.Projects where
|
||||
|
||||
import Data.Proxy
|
||||
import Servant.API ((:<|>) (..))
|
||||
import Servant.Client
|
||||
import Unison.Prelude
|
||||
import Unison.Share.API.Projects
|
||||
|
||||
getProject0 :: Maybe Text -> Maybe Text -> ClientM GetProjectResponse
|
||||
createProject :: CreateProjectRequest -> ClientM CreateProjectResponse
|
||||
getProjectBranch :: Text -> Maybe Text -> Maybe Text -> ClientM GetProjectBranchResponse
|
||||
createProjectBranch :: CreateProjectBranchRequest -> ClientM CreateProjectBranchResponse
|
||||
setProjectBranchHead :: SetProjectBranchHeadRequest -> ClientM SetProjectBranchHeadResponse
|
||||
( getProject0
|
||||
:<|> createProject
|
||||
:<|> getProjectBranch
|
||||
:<|> createProjectBranch
|
||||
:<|> setProjectBranchHead
|
||||
) =
|
||||
hoistClient projectsAPI id (client projectsAPI)
|
||||
where
|
||||
projectsAPI :: Proxy ProjectsAPI
|
||||
projectsAPI = Proxy
|
@ -35,6 +35,7 @@ library
|
||||
Unison.Cli.NamesUtils
|
||||
Unison.Cli.PrettyPrintUtils
|
||||
Unison.Cli.ProjectUtils
|
||||
Unison.Cli.Share.Projects
|
||||
Unison.Cli.TypeCheck
|
||||
Unison.Cli.UnisonConfigUtils
|
||||
Unison.Codebase.Editor.AuthorInfo
|
||||
@ -196,6 +197,7 @@ library
|
||||
, unison-prelude
|
||||
, unison-pretty-printer
|
||||
, unison-share-api
|
||||
, unison-share-projects-api
|
||||
, unison-sqlite
|
||||
, unison-syntax
|
||||
, unison-util-base32hex
|
||||
@ -326,6 +328,7 @@ executable cli-integration-tests
|
||||
, unison-prelude
|
||||
, unison-pretty-printer
|
||||
, unison-share-api
|
||||
, unison-share-projects-api
|
||||
, unison-sqlite
|
||||
, unison-syntax
|
||||
, unison-util-base32hex
|
||||
@ -450,6 +453,7 @@ executable transcripts
|
||||
, unison-prelude
|
||||
, unison-pretty-printer
|
||||
, unison-share-api
|
||||
, unison-share-projects-api
|
||||
, unison-sqlite
|
||||
, unison-syntax
|
||||
, unison-util-base32hex
|
||||
@ -581,6 +585,7 @@ executable unison
|
||||
, unison-prelude
|
||||
, unison-pretty-printer
|
||||
, unison-share-api
|
||||
, unison-share-projects-api
|
||||
, unison-sqlite
|
||||
, unison-syntax
|
||||
, unison-util-base32hex
|
||||
@ -715,6 +720,7 @@ test-suite cli-tests
|
||||
, unison-prelude
|
||||
, unison-pretty-printer
|
||||
, unison-share-api
|
||||
, unison-share-projects-api
|
||||
, unison-sqlite
|
||||
, unison-syntax
|
||||
, unison-util-base32hex
|
||||
|
Loading…
Reference in New Issue
Block a user