Skip to content

Commit

Permalink
Merge pull request #905 from IntersectMBO/jordan/deprecate-legacy-com…
Browse files Browse the repository at this point in the history
…mands

Remove legacy commands
  • Loading branch information
Jimbo4350 authored Sep 26, 2024
2 parents d61153c + 935cea1 commit 74ff1d6
Showing 293 changed files with 9,473 additions and 18,644 deletions.
17 changes: 0 additions & 17 deletions cardano-cli/cardano-cli.cabal
Original file line number Diff line number Diff line change
@@ -121,29 +121,12 @@ library
Cardano.CLI.IO.Lazy
Cardano.CLI.Json.Friendly
Cardano.CLI.Legacy.Commands
Cardano.CLI.Legacy.Commands.Address
Cardano.CLI.Legacy.Commands.Genesis
Cardano.CLI.Legacy.Commands.Governance
Cardano.CLI.Legacy.Commands.Key
Cardano.CLI.Legacy.Commands.Node
Cardano.CLI.Legacy.Commands.Query
Cardano.CLI.Legacy.Commands.StakeAddress
Cardano.CLI.Legacy.Commands.StakePool
Cardano.CLI.Legacy.Commands.TextView
Cardano.CLI.Legacy.Commands.Transaction
Cardano.CLI.Legacy.Options
Cardano.CLI.Legacy.Options.Key
Cardano.CLI.Legacy.Run
Cardano.CLI.Legacy.Run.Address
Cardano.CLI.Legacy.Run.Genesis
Cardano.CLI.Legacy.Run.Governance
Cardano.CLI.Legacy.Run.Key
Cardano.CLI.Legacy.Run.Node
Cardano.CLI.Legacy.Run.Query
Cardano.CLI.Legacy.Run.StakeAddress
Cardano.CLI.Legacy.Run.StakePool
Cardano.CLI.Legacy.Run.TextView
Cardano.CLI.Legacy.Run.Transaction
Cardano.CLI.OS.Posix
Cardano.CLI.Options
Cardano.CLI.Options.Debug
4 changes: 2 additions & 2 deletions cardano-cli/src/Cardano/CLI/EraBased/Commands.hs
Original file line number Diff line number Diff line change
@@ -108,8 +108,8 @@ pAnyEraCommand envCli =
Opt.info (AnyEraCommandOf ShelleyBasedEraConway <$> pCmds ShelleyBasedEraConway envCli) $
Opt.progDesc "Conway era commands"
, subParser "latest" $
Opt.info (AnyEraCommandOf ShelleyBasedEraBabbage <$> pCmds ShelleyBasedEraBabbage envCli) $
Opt.progDesc ("Latest era commands (Babbage)" <> deprecationText)
Opt.info (AnyEraCommandOf ShelleyBasedEraConway <$> pCmds ShelleyBasedEraConway envCli) $
Opt.progDesc "Latest era commands (Conway)"
]

pCmds :: ShelleyBasedEra era -> EnvCli -> Parser (Cmds era)
34 changes: 1 addition & 33 deletions cardano-cli/src/Cardano/CLI/Legacy/Commands.hs
Original file line number Diff line number Diff line change
@@ -6,50 +6,18 @@ module Cardano.CLI.Legacy.Commands
)
where

import Cardano.CLI.Legacy.Commands.Address
import Cardano.CLI.Legacy.Commands.Genesis
import Cardano.CLI.Legacy.Commands.Governance
import Cardano.CLI.Legacy.Commands.Key
import Cardano.CLI.Legacy.Commands.Node
import Cardano.CLI.Legacy.Commands.Query
import Cardano.CLI.Legacy.Commands.StakeAddress
import Cardano.CLI.Legacy.Commands.StakePool
import Cardano.CLI.Legacy.Commands.TextView
import Cardano.CLI.Legacy.Commands.Transaction

import Data.Text (Text)

data LegacyCmds
= LegacyAddressCmds LegacyAddressCmds
| LegacyGenesisCmds LegacyGenesisCmds
= LegacyGenesisCmds LegacyGenesisCmds
| LegacyGovernanceCmds LegacyGovernanceCmds
| LegacyKeyCmds LegacyKeyCmds
| LegacyNodeCmds LegacyNodeCmds
| LegacyQueryCmds LegacyQueryCmds
| LegacyStakeAddressCmds LegacyStakeAddressCmds
| LegacyStakePoolCmds LegacyStakePoolCmds
| LegacyTextViewCmds LegacyTextViewCmds
| LegacyTransactionCmds LegacyTransactionCmds

renderLegacyCommand :: LegacyCmds -> Text
renderLegacyCommand = \case
LegacyAddressCmds cmd ->
renderLegacyAddressCmds cmd
LegacyStakeAddressCmds cmd ->
renderLegacyStakeAddressCmds cmd
LegacyKeyCmds cmd ->
renderLegacyKeyCmds cmd
LegacyTransactionCmds cmd ->
renderLegacyTransactionCmds cmd
LegacyNodeCmds cmd ->
renderLegacyNodeCmds cmd
LegacyStakePoolCmds cmd ->
renderLegacyStakePoolCmds cmd
LegacyQueryCmds cmd ->
renderLegacyQueryCmds cmd
LegacyGovernanceCmds cmd ->
renderLegacyGovernanceCmds cmd
LegacyGenesisCmds cmd ->
renderLegacyGenesisCmds cmd
LegacyTextViewCmds cmd ->
renderLegacyTextViewCmds cmd
43 changes: 0 additions & 43 deletions cardano-cli/src/Cardano/CLI/Legacy/Commands/Address.hs

This file was deleted.

55 changes: 0 additions & 55 deletions cardano-cli/src/Cardano/CLI/Legacy/Commands/Key.hs

This file was deleted.

30 changes: 0 additions & 30 deletions cardano-cli/src/Cardano/CLI/Legacy/Commands/Node.hs

This file was deleted.

Loading

0 comments on commit 74ff1d6

Please sign in to comment.