hs-cli
hs-cli copied to clipboard
Argument crashes with command
Hello This code:
import Console.Options
main = defaultMain $ do
arg <- argument "" $ \raw -> Right raw
command "sample" $
action $ \toParam ->
putStrLn $ show $ toParam arg
throws error:
Prelude.!!: index too large
whereas this code:
import Console.Options
main = defaultMain $ do
arg <- argument "" $ \raw -> Right raw
action $ \toParam ->
putStrLn $ show $ toParam arg
works well
version 0.2.0