mirror of
https://github.com/aelve/guide.git
synced 2024-12-23 12:52:31 +03:00
17 lines
469 B
Haskell
17 lines
469 B
Haskell
import Distribution.Simple
|
|
import System.Process
|
|
|
|
main = do
|
|
hooks <- buildJS simpleUserHooks
|
|
defaultMainWithHooks hooks
|
|
|
|
buildJS hooks = do
|
|
let originalPostBuild = postBuild hooks
|
|
return $ hooks {
|
|
postBuild = \args flags pkgDesc localBuildInfo -> do
|
|
let npmbuild = proc "sh" ["./scripts/buildjs.sh"]
|
|
(_, _, _, buildHandle) <- createProcess npmbuild
|
|
waitForProcess buildHandle
|
|
originalPostBuild args flags pkgDesc localBuildInfo
|
|
}
|