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