module Proteome.Data.ProjectRoot where

import Path (Abs, Dir, Path)
import Ribosome (MsgpackDecode, MsgpackEncode)

newtype ProjectRoot =
  ProjectRoot { ProjectRoot -> Path Abs Dir
unProjectRoot :: Path Abs Dir }
  deriving stock (ProjectRoot -> ProjectRoot -> Bool
(ProjectRoot -> ProjectRoot -> Bool)
-> (ProjectRoot -> ProjectRoot -> Bool) -> Eq ProjectRoot
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ProjectRoot -> ProjectRoot -> Bool
$c/= :: ProjectRoot -> ProjectRoot -> Bool
== :: ProjectRoot -> ProjectRoot -> Bool
$c== :: ProjectRoot -> ProjectRoot -> Bool
Eq, Int -> ProjectRoot -> ShowS
[ProjectRoot] -> ShowS
ProjectRoot -> String
(Int -> ProjectRoot -> ShowS)
-> (ProjectRoot -> String)
-> ([ProjectRoot] -> ShowS)
-> Show ProjectRoot
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ProjectRoot] -> ShowS
$cshowList :: [ProjectRoot] -> ShowS
show :: ProjectRoot -> String
$cshow :: ProjectRoot -> String
showsPrec :: Int -> ProjectRoot -> ShowS
$cshowsPrec :: Int -> ProjectRoot -> ShowS
Show, (forall x. ProjectRoot -> Rep ProjectRoot x)
-> (forall x. Rep ProjectRoot x -> ProjectRoot)
-> Generic ProjectRoot
forall x. Rep ProjectRoot x -> ProjectRoot
forall x. ProjectRoot -> Rep ProjectRoot x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ProjectRoot x -> ProjectRoot
$cfrom :: forall x. ProjectRoot -> Rep ProjectRoot x
Generic)
  deriving newtype (Object -> Either DecodeError ProjectRoot
(Object -> Either DecodeError ProjectRoot)
-> MsgpackDecode ProjectRoot
forall a. (Object -> Either DecodeError a) -> MsgpackDecode a
fromMsgpack :: Object -> Either DecodeError ProjectRoot
$cfromMsgpack :: Object -> Either DecodeError ProjectRoot
MsgpackDecode, ProjectRoot -> Object
(ProjectRoot -> Object) -> MsgpackEncode ProjectRoot
forall a. (a -> Object) -> MsgpackEncode a
toMsgpack :: ProjectRoot -> Object
$ctoMsgpack :: ProjectRoot -> Object
MsgpackEncode)