Skip to content

Commit

Permalink
Fixup legacy Ignore parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
pbrisbin committed Oct 18, 2024
1 parent ef2384c commit 0c6d7b9
Showing 1 changed file with 12 additions and 24 deletions.
36 changes: 12 additions & 24 deletions src/Restyler/Config/Ignore.hs
Original file line number Diff line number Diff line change
Expand Up @@ -55,28 +55,16 @@ newIgnoresParser =

oldIgnoresParsers :: [Parser Ignores]
oldIgnoresParsers =
[ Ignores
<$> setting
[ help ""
, conf "ignore_authors"
, hidden
]
<*> pure []
<*> pure []
, Ignores
<$> setting
[ help ""
, conf "ignore_branches"
, hidden
]
<*> pure []
<*> pure []
, Ignores
<$> setting
[ help ""
, conf "ignore_labels"
, hidden
]
<*> pure []
<*> pure []
[ Ignores <$> hiddenIgnoreParser "ignore_authors" <*> pure [] <*> pure []
, Ignores [] <$> hiddenIgnoreParser "ignore_branches" <*> pure []
, Ignores [] [] <$> hiddenIgnoreParser "ignore_labels"
]

hiddenIgnoreParser :: String -> Parser [Glob Text]
hiddenIgnoreParser key =
setting
[ help ""
, conf key
, hidden
]
<|> pure []

0 comments on commit 0c6d7b9

Please sign in to comment.