merge add package header

This commit is contained in:
Lucy Cifferello
2021-07-01 18:39:15 -04:00
committed by Keagan McClelland
parent 66cc783321
commit 16bb00a230
5 changed files with 23 additions and 4 deletions

View File

@@ -61,4 +61,11 @@ getIcon appmgrPath appPath e@(Extension icon) = do
(ec, bs) <- readProcessInheritStderr (appmgrPath <> "embassy-sdk") ["inspect", "icon", appPath <> show e] ""
case ec of
ExitSuccess -> pure bs
ExitFailure n -> throwE $ AppMgrE [i|icon #{icon} \--json|] n
ExitFailure n -> throwE $ AppMgrE [i|icon #{icon} \--json|] n
getPackageHash :: (MonadIO m, KnownSymbol a) => FilePath -> FilePath -> Extension a -> S9ErrT m ByteString
getPackageHash appmgrPath appPath e@(Extension appId) = do
(ec, bs) <- readProcessInheritStderr (appmgrPath <> "embassy-sdk") ["inspect", "hash", appPath <> show e] ""
case ec of
ExitSuccess -> pure bs
ExitFailure n -> throwE $ AppMgrE [i|hash #{appId} \--json|] n