Skip to content

Instantly share code, notes, and snippets.

@nobsun
Created December 26, 2023 03:53
Show Gist options
  • Save nobsun/ad7c869e952850df73d32e9516a44c6a to your computer and use it in GitHub Desktop.
Save nobsun/ad7c869e952850df73d32e9516a44c6a to your computer and use it in GitHub Desktop.
{-# LANGUAGE GHC2021 #-}
{-# LANGUAGE ImportQualifiedPost #-}
{-# LANGUAGE LexicalNegation #-}
{-# LANGUAGE LambdaCase, MultiWayIf #-}
{-# LANGUAGE NPlusKPatterns #-}
{-# LANGUAGE DataKinds, PolyKinds, NoStarIsType, TypeFamilyDependencies #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE OverloadedRecordDot, NoFieldSelectors, DuplicateRecordFields #-}
module Main where
import System.Environment
import InitModule
main :: IO ()
main = do
{ prog <- getProgName
; args <- getArgs
; case args of
[] -> usage prog
_ -> mapM_ initModule args
}
usage :: String -> IO ()
usage prog = putStrLn $ unwords
[ prog
, "<module-name>"
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment