mirror of
https://github.com/wasp-lang/wasp.git
synced 2024-11-24 11:44:51 +03:00
a70effa6db
Start does not yet work properly.
37 lines
701 B
Haskell
37 lines
701 B
Haskell
module Main where
|
|
|
|
import System.Environment
|
|
|
|
import Command (runCommand)
|
|
import Command.CreateNewProject (createNewProject)
|
|
import Command.Start (start)
|
|
import Command.Clean (clean)
|
|
|
|
|
|
main :: IO ()
|
|
main = do
|
|
args <- getArgs
|
|
case args of
|
|
["new", projectName] -> runCommand $ createNewProject projectName
|
|
["start"] -> runCommand start
|
|
["clean"] -> runCommand clean
|
|
_ -> printUsage
|
|
|
|
printUsage :: IO ()
|
|
printUsage = putStrLn $ unlines
|
|
[ "Usage:"
|
|
, " wasp <command> [command-args]"
|
|
, ""
|
|
, "Commands:"
|
|
, " new <project-name>"
|
|
, " start"
|
|
, " clean"
|
|
, ""
|
|
, "Examples:"
|
|
, " wasp create MyApp"
|
|
, " wasp start"
|
|
]
|
|
|
|
|
|
|