Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data ShareCodeserver
- newtype ShareUserHandle = ShareUserHandle {}
- displayShareCodeserver :: ShareCodeserver -> ShareUserHandle -> Path -> Text
- printReadRemoteNamespace :: (a -> Text) -> ReadRemoteNamespace a -> Text
- printWriteRemoteNamespace :: ProjectAndBranch ProjectName ProjectBranchName -> Text
- maybePrintPath :: Path -> Text
- data ReadRemoteNamespace a
- data ReadShareLooseCode = ReadShareLooseCode {
- server :: !ShareCodeserver
- repo :: !ShareUserHandle
- path :: !Path
- isPublic :: ReadShareLooseCode -> Bool
Documentation
displayShareCodeserver :: ShareCodeserver -> ShareUserHandle -> Path -> Text Source #
>>>
:set -XOverloadedLists
>>>
import Data.Maybe (fromJust)
>>>
import Network.URI
>>>
displayShareCodeserver DefaultCodeserver "share" ["base", "List"]
"share.base.List">>>
displayShareCodeserver DefaultCodeserver "share" []
"share">>>
displayShareCodeserver (CustomCodeserver . fromJust $ parseURI "https://share-next.unison-lang.org/api" >>= codeserverFromURI ) "unison" ["base", "List"]
"share(https://share-next.unison-lang.org:443/api).unison.base.List"
printReadRemoteNamespace :: (a -> Text) -> ReadRemoteNamespace a -> Text Source #
print remote namespace
printWriteRemoteNamespace :: ProjectAndBranch ProjectName ProjectBranchName -> Text Source #
Render a WriteRemoteNamespace
as text.
maybePrintPath :: Path -> Text Source #
data ReadRemoteNamespace a Source #
ReadShare'LooseCode !ReadShareLooseCode | |
ReadShare'ProjectBranch !a | A remote project+branch, specified by name (e.g. @unisonbasemain). Currently assumed to be hosted on Share, though we could include a ShareCodeserver in here, too. |
Instances
data ReadShareLooseCode Source #
ReadShareLooseCode | |
|
Instances
isPublic :: ReadShareLooseCode -> Bool Source #