Skip to content

Fix typos in hls-cabal-fmt-plugin #4399

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions plugins/hls-cabal-fmt-plugin/src/Ide/Plugin/CabalFmt.hs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ provider recorder _ _ _ (FormatRange _) _ _ _ = do
throwError $ PluginInvalidParams "You cannot format a text-range using cabal-fmt."
provider recorder plId ideState _ FormatText contents nfp opts = do
let cabalFmtArgs = [ "--indent", show tabularSize]
cabalFmtExePath <- fmap T.unpack $ liftIO $ runAction "cabal-gild" ideState $ usePropertyAction #path plId properties
cabalFmtExePath <- fmap T.unpack $ liftIO $ runAction "cabal-fmt" ideState $ usePropertyAction #path plId properties
x <- liftIO $ findExecutable cabalFmtExePath
case x of
Just _ -> do
Expand All @@ -85,7 +85,7 @@ provider recorder plId ideState _ FormatText contents nfp opts = do
pure $ InL fmtDiff
Nothing -> do
log Error $ LogFormatterBinNotFound cabalFmtExePath
throwError (PluginInternalError "No installation of cabal-gild could be found. Please install it globally, or provide the full path to the executable")
throwError (PluginInternalError "No installation of cabal-fmt could be found. Please install it globally, or provide the full path to the executable")
where
fp = fromNormalizedFilePath nfp
tabularSize = opts ^. L.tabSize
Expand Down
Loading