mirror of
https://github.com/koalaman/shellcheck.git
synced 2025-08-08 08:01:12 +08:00
Add a pre-sdist hook to compile the man page (Github issue #247).
This replaces the default preSDist hook in Setup.hs with our own. The only thing the new hook does is compile the man page using callCommand from System.Process. If Pandoc fails, the entire sdist process will fail, since Extra-Source-Files in the cabal file now lists the man page. This is preferable to a build hook, because Pandoc pulls in a huge number of dependencies. It's better to build the man page once and ship it than to require every user to build and install pandoc before he can build ShellCheck. This creates another TODO item: an install hook can now be used to install the man page along with the rest of ShellCheck. But beware, the "man path" can vary from system to system.
This commit is contained in:
@@ -26,6 +26,8 @@ Extra-Source-Files:
|
||||
-- documentation
|
||||
README.md
|
||||
shellcheck.1.md
|
||||
-- built with a cabal sdist hook
|
||||
shellcheck.1
|
||||
-- tests
|
||||
test/shellcheck.hs
|
||||
|
||||
|
Reference in New Issue
Block a user