Skip to content

Commit

Permalink
Satisfy fourmolu
Browse files Browse the repository at this point in the history
  • Loading branch information
philderbeast committed Dec 28, 2024
1 parent dba79d8 commit 3cfe8b4
Showing 1 changed file with 12 additions and 11 deletions.
23 changes: 12 additions & 11 deletions cabal-install/src/Distribution/Client/CmdRepl.hs
Original file line number Diff line number Diff line change
Expand Up @@ -301,17 +301,18 @@ replAction flags@NixStyleFlags{extraFlags = r@ReplFlags{..}, ..} targetStrings g
project punct = case projectConfigProjectFile . projectConfigShared $ projectConfig ctx of
Flag projectName -> comma <+> (quotes (text projectName) <> punct)
_ -> Pretty.empty
msg = if null pkgs
then
intro Pretty.empty
<+> (text "but there are no packages in this project" <> project comma)
<+> text "to choose a package (library) or other component from"
<+> "as the target for this command."
else
intro (char '.')
<+> (text "The packages in this project" <> project comma)
<+> (text "are" <> colon)
$+$ nest 1 (vcat [text "-" <+> text pkg | pkg <- sort pkgs])
msg =
if null pkgs
then
intro Pretty.empty
<+> (text "but there are no packages in this project" <> project comma)
<+> text "to choose a package (library) or other component from"
<+> "as the target for this command."
else
intro (char '.')
<+> (text "The packages in this project" <> project comma)
<+> (text "are" <> colon)
$+$ nest 1 (vcat [text "-" <+> text pkg | pkg <- sort pkgs])
in dieWithException verbosity $ RenderReplTargetProblem [render msg]
return ctx
GlobalContext -> do
Expand Down

0 comments on commit 3cfe8b4

Please sign in to comment.