Skip to content
This repository was archived by the owner on Oct 7, 2020. It is now read-only.

Commit 44c6fb3

Browse files
committed
Remove plugin names and descriptions
Now redundant as they were just used to return information via the JSON transport when querying plugins
1 parent 1a57c7b commit 44c6fb3

File tree

14 files changed

+1
-29
lines changed

14 files changed

+1
-29
lines changed

hie-plugin-api/Haskell/Ide/Engine/PluginsIdeMonads.hs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -262,8 +262,6 @@ type FormattingProvider = T.Text -- ^ Text to format
262262

263263
data PluginDescriptor =
264264
PluginDescriptor { pluginId :: PluginId
265-
, pluginName :: T.Text
266-
, pluginDesc :: T.Text
267265
, pluginCommands :: [PluginCommand]
268266
, pluginCodeActionProvider :: Maybe CodeActionProvider
269267
, pluginDiagnosticProvider :: Maybe DiagnosticProvider
@@ -596,7 +594,7 @@ instance ExceptionMonad m => ExceptionMonad (ReaderT e m) where
596594
q u (ReaderT b) = ReaderT (u . b)
597595

598596
instance MonadTrans GhcT where
599-
lift m = liftGhcT m
597+
lift = liftGhcT
600598

601599

602600
instance MonadUnliftIO Ghc where

src/Haskell/Ide/Engine/Plugin/ApplyRefact.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,6 @@ type HintTitle = T.Text
4141
applyRefactDescriptor :: PluginId -> PluginDescriptor
4242
applyRefactDescriptor plId = PluginDescriptor
4343
{ pluginId = plId
44-
, pluginName = "ApplyRefact"
45-
, pluginDesc = "apply-refact applies refactorings specified by the refact package. It is currently integrated into hlint to enable the automatic application of suggestions."
4644
, pluginCommands =
4745
[ PluginCommand "applyOne" "Apply a single hint" applyOneCmd
4846
, PluginCommand "applyAll" "Apply all hints to the file" applyAllCmd

src/Haskell/Ide/Engine/Plugin/Bios.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@ import Haskell.Ide.Engine.Ghc
1515
biosDescriptor :: PluginId -> PluginDescriptor
1616
biosDescriptor plId = PluginDescriptor
1717
{ pluginId = plId
18-
, pluginName = "bios"
19-
, pluginDesc = "bios"
2018
, pluginCommands =
2119
[PluginCommand "check" "check a file for GHC warnings and errors" checkCmd]
2220
, pluginCodeActionProvider = Nothing

src/Haskell/Ide/Engine/Plugin/Brittany.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ import Data.Maybe (maybeToList)
2020
brittanyDescriptor :: PluginId -> PluginDescriptor
2121
brittanyDescriptor plId = PluginDescriptor
2222
{ pluginId = plId
23-
, pluginName = "Brittany"
24-
, pluginDesc = "Brittany is a tool to format source code."
2523
, pluginCommands = []
2624
, pluginCodeActionProvider = Nothing
2725
, pluginDiagnosticProvider = Nothing

src/Haskell/Ide/Engine/Plugin/Example2.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ import qualified Language.Haskell.LSP.Types.Lens as J
2222
example2Descriptor :: PluginId -> PluginDescriptor
2323
example2Descriptor plId = PluginDescriptor
2424
{ pluginId = plId
25-
, pluginName = "Hello World"
26-
, pluginDesc = "An example of writing an HIE plugin"
2725
, pluginCommands =
2826
[ PluginCommand "sayHello" "say hello" sayHelloCmd
2927
, PluginCommand "sayHelloTo ""say hello to the passed in param" sayHelloToCmd

src/Haskell/Ide/Engine/Plugin/Floskell.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@ import Haskell.Ide.Engine.PluginUtils
1717
floskellDescriptor :: PluginId -> PluginDescriptor
1818
floskellDescriptor plId = PluginDescriptor
1919
{ pluginId = plId
20-
, pluginName = "Floskell"
21-
, pluginDesc = "A flexible Haskell source code pretty printer."
2220
, pluginCommands = []
2321
, pluginCodeActionProvider = Nothing
2422
, pluginDiagnosticProvider = Nothing

src/Haskell/Ide/Engine/Plugin/Generic.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,6 @@ import PprTyThing
4343
genericDescriptor :: PluginId -> PluginDescriptor
4444
genericDescriptor plId = PluginDescriptor
4545
{ pluginId = plId
46-
, pluginName = "generic"
47-
, pluginDesc = "generic actions"
4846
, pluginCommands = [PluginCommand "type" "Get the type of the expression under (LINE,COL)" typeCmd]
4947
, pluginCodeActionProvider = Just codeActionProvider
5048
, pluginDiagnosticProvider = Nothing

src/Haskell/Ide/Engine/Plugin/Haddock.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ import Documentation.Haddock.Types
3434
haddockDescriptor :: PluginId -> PluginDescriptor
3535
haddockDescriptor plId = PluginDescriptor
3636
{ pluginId = plId
37-
, pluginName = "Haddock"
38-
, pluginDesc = "Fishy documentation"
3937
, pluginCommands = []
4038
, pluginCodeActionProvider = Nothing
4139
, pluginDiagnosticProvider = Nothing

src/Haskell/Ide/Engine/Plugin/HfaAlign.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,6 @@ import qualified Safe
2828
hfaAlignDescriptor :: PluginId -> PluginDescriptor
2929
hfaAlignDescriptor plId = PluginDescriptor
3030
{ pluginId = plId
31-
, pluginName = "Align Equals"
32-
, pluginDesc = "An example of writing an HIE plugin\nbased on http://www.haskellforall.com/2018/10/detailed-walkthrough-for-beginner.html"
3331
, pluginCommands =
3432
[ PluginCommand "align" "Align = in active range" alignCmd
3533
]

src/Haskell/Ide/Engine/Plugin/HsImport.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,6 @@ import qualified Safe as S
3131
hsimportDescriptor :: PluginId -> PluginDescriptor
3232
hsimportDescriptor plId = PluginDescriptor
3333
{ pluginId = plId
34-
, pluginName = "HsImport"
35-
, pluginDesc = "A tool for extending the import list of a Haskell source file."
3634
, pluginCommands = [PluginCommand "import" "Import a module" importModule]
3735
, pluginCodeActionProvider = Just codeActionProvider
3836
, pluginDiagnosticProvider = Nothing

src/Haskell/Ide/Engine/Plugin/Liquid.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,6 @@ import Text.Parsec.Text
3333
liquidDescriptor :: PluginId -> PluginDescriptor
3434
liquidDescriptor plId = PluginDescriptor
3535
{ pluginId = plId
36-
, pluginName = "Liquid Haskell"
37-
, pluginDesc = "Integration with Liquid Haskell"
3836
, pluginCommands = []
3937
, pluginCodeActionProvider = Nothing
4038
, pluginDiagnosticProvider = Just (DiagnosticProvider

src/Haskell/Ide/Engine/Plugin/Package.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,6 @@ import qualified Data.Yaml as Y
5353
packageDescriptor :: T.Text -> PluginDescriptor
5454
packageDescriptor plId = PluginDescriptor
5555
{ pluginId = plId
56-
, pluginName = "package"
57-
, pluginDesc = "Tools for editing .cabal and package.yaml files."
5856
, pluginCommands = [PluginCommand "add" "Add a packge" addCmd]
5957
, pluginCodeActionProvider = Just codeActionProvider
6058
, pluginDiagnosticProvider = Nothing

src/Haskell/Ide/Engine/Plugin/Pragmas.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ import qualified Language.Haskell.LSP.Types.Lens as J
1818
pragmasDescriptor :: PluginId -> PluginDescriptor
1919
pragmasDescriptor plId = PluginDescriptor
2020
{ pluginId = plId
21-
, pluginName = "Add Missing Pragmas"
22-
, pluginDesc = "Provide code actions to add missing pragmas when GHC suggests this"
2321
, pluginCommands =
2422
[ PluginCommand "addPragma" "add the given pragma" addPragmaCmd
2523
]

test/unit/ExtensibleStateSpec.hs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,6 @@ testPlugins = pluginDescToIdePlugins [testDescriptor "test"]
3535
testDescriptor :: PluginId -> PluginDescriptor
3636
testDescriptor plId = PluginDescriptor
3737
{ pluginId = plId
38-
, pluginName = "testDescriptor"
39-
, pluginDesc = "PluginDescriptor for testing Dispatcher"
4038
, pluginCommands = [
4139
PluginCommand "cmd1" "description" cmd1
4240
, PluginCommand "cmd2" "description" cmd2

0 commit comments

Comments
 (0)