diff --git a/Setup.hs b/Setup.hs
--- a/Setup.hs
+++ b/Setup.hs
@@ -1,12 +1,52 @@
+{-# LANGUAGE TemplateHaskell #-}
+
+import           Control.Monad       (unless, void)
+import           Data.FileEmbed      (embedStringFile)
+import           Data.Maybe
 import           Distribution.Simple
+import           System.Directory    (createDirectoryIfMissing)
 import           System.Environment  (lookupEnv)
+import           System.Process      (readCreateProcessWithExitCode, shell)
 
-main = writeBashCompletions >> defaultMain
+manpage :: String
+manpage = $(embedStringFile "man/madlang.1")
 
+main :: IO ()
+main = setManpath >>
+    writeManpages >>
+    writeBashCompletions >>
+    defaultMain
+
+setManpath :: IO ()
+setManpath = do
+    home <- lookupEnv "HOME"
+    case home of
+        Just x -> do
+            let bashRc = x ++ "/.bashrc"
+            config <- readFile bashRc
+            unless ("#manpath updated by madlang" `elem` lines config)
+                (appendFile bashRc "\n#manpath updated by madlang\nexport MANPATH=~/.local/share:$MANPATH\n" >>
+                 void (readCreateProcessWithExitCode (shell "MANPATH=~/.local/share:$MANPATH mandb") ""))
+        Nothing -> pure ()
+
+writeManpages :: IO ()
+writeManpages = do
+    home <- lookupEnv "HOME"
+    case home of
+        Just x -> do
+            let manPath = x ++ "/.local/share/man/man1"
+            createDirectoryIfMissing True manPath
+            writeFile (manPath ++ "/madlang.1") manpage
+        Nothing -> pure ()
+
 -- TODO only write if we can't find our own thing!
 writeBashCompletions :: IO ()
 writeBashCompletions = do
     home <- lookupEnv "HOME"
     case home of
-        Just x -> appendFile (x ++ "/.bashrc") "\n# Added by madlang\neval \"$(madlang --bash-completion-script madlang)\"\n"
+        Just x -> do
+            let bashRc = x ++ "/.bashrc"
+            config <- readFile bashRc
+            unless ("# Added by madlang" `elem` lines config)
+                (appendFile bashRc "\n# Added by madlang\neval \"$(madlang --bash-completion-script madlang)\"\n")
         Nothing -> pure ()
diff --git a/madlang.cabal b/madlang.cabal
--- a/madlang.cabal
+++ b/madlang.cabal
@@ -1,5 +1,5 @@
 name:                madlang
-version:             2.4.1.5
+version:             2.4.1.6
 synopsis:            Randomized templating language DSL
 description:         Madlang is a text templating language written in Haskell,
                      meant to explore computational creativity and generative
@@ -21,6 +21,13 @@
                    , cabal.project.local
                    , man/madlang.1
 cabal-version:       >=1.10
+
+custom-setup
+  setup-depends:   base
+                 , Cabal
+                 , file-embed
+                 , directory
+                 , process
 
 Flag development {
   Description: Turn on '-Werror'
diff --git a/src/Text/Madlibs/Exec/Main.hs b/src/Text/Madlibs/Exec/Main.hs
--- a/src/Text/Madlibs/Exec/Main.hs
+++ b/src/Text/Madlibs/Exec/Main.hs
@@ -33,7 +33,7 @@
         (command "run" (info temp (progDesc "Generate text from a .mad file"))
         <> command "debug" (info debug (progDesc "Debug a template"))
         <> command "lint" (info lint (progDesc "Lint a file"))
-        <> command "install" (info (pure Install) (progDesc "Install shell completions for bash and manpages"))
+        <> command "install" (info (pure Install) (progDesc "Install/update prebundled libraries."))
         ))
 
 -- | Parser for the run subcommand
