loadStylesheet :: FilePath -> IO ByteString
loadStylesheet p = do
    l <- findLessc
    (exitCode, out, err) <- readProcessWithExitCode' l [p, "/dev/stdout"] ""
    when (exitCode /= ExitSuccess) $ error $ p ++ ": " ++ U.toString err
    return out


------------------------------------------------------------------------------
-- | Given the path to a directory containing @.less@ files, this returns a
-- map from the names of those @.less@ files with the @.less@ replaced with
-- @.css@ to the contents of those files after being processed with the
-- @lessc@ command.
loadStylesheet :: FilePath -> IO ByteString
loadStylesheet p = do
    l <- findLessc
    (exitCode, out, err) <- readProcessWithExitCode' l [p, "/dev/stdout"] ""
    when (exitCode /= ExitSuccess) $ error $ p ++ ": " ++ U.toString err
    return out


------------------------------------------------------------------------------
-- | Given the path to a directory containing @.less@ files, this returns a
-- map from the names of those @.less@ files with the @.less@ replaced with
-- @.css@ to the contents of those files after being processed with the
-- @lessc@ command.
loadStylesheet p = do
    l <- findLessc
    (exitCode, out, err) <- readProcessWithExitCode' l [p, "/dev/stdout"] ""
    when (exitCode /= ExitSuccess) $ error $ p ++ ": " ++ U.toString err
    return out


------------------------------------------------------------------------------
-- | Given the path to a directory containing @.less@ files, this returns a
-- map from the names of those @.less@ files with the @.less@ replaced with
-- @.css@ to the contents of those files after being processed with the
-- @lessc@ command.