From 944056080226de13cfc94cef826810b129685aef Mon Sep 17 00:00:00 2001 From: Mateusz Galazyn Date: Fri, 30 Aug 2024 14:50:46 +0200 Subject: [PATCH] introducing experimental eras code --- cabal.project | 7 + cardano-cli/src/Cardano/CLI/Environment.hs | 18 +- .../src/Cardano/CLI/EraBased/Commands.hs | 19 +- .../CLI/EraBased/Commands/Transaction.hs | 5 +- .../Cardano/CLI/EraBased/Options/Common.hs | 19 +- .../CLI/EraBased/Options/Transaction.hs | 31 +- .../Cardano/CLI/EraBased/Run/Transaction.hs | 60 +- .../CLI/Legacy/Commands/Transaction.hs | 3 +- cardano-cli/src/Cardano/CLI/Legacy/Options.hs | 25 +- .../src/Cardano/CLI/Legacy/Run/Transaction.hs | 8 +- .../cardano-cli-golden/files/golden/help.cli | 778 +----------------- .../files/golden/help/allegra_transaction.cli | 4 - .../golden/help/allegra_transaction_build.cli | 393 --------- .../files/golden/help/alonzo_transaction.cli | 8 - .../golden/help/alonzo_transaction_build.cli | 393 --------- .../golden/help/legacy_transaction_build.cli | 19 +- .../files/golden/help/mary_transaction.cli | 8 - .../golden/help/mary_transaction_build.cli | 391 --------- .../files/golden/help/shelley_transaction.cli | 4 - .../golden/help/shelley_transaction_build.cli | 393 --------- .../files/golden/help/transaction_build.cli | 19 +- 21 files changed, 123 insertions(+), 2482 deletions(-) delete mode 100644 cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_transaction_build.cli delete mode 100644 cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_transaction_build.cli delete mode 100644 cardano-cli/test/cardano-cli-golden/files/golden/help/mary_transaction_build.cli delete mode 100644 cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_transaction_build.cli diff --git a/cabal.project b/cabal.project index ba972eee30..b738973479 100644 --- a/cabal.project +++ b/cabal.project @@ -57,3 +57,10 @@ write-ghc-environment-files: always -- IMPORTANT -- Do NOT add more source-repository-package stanzas here unless they are strictly -- temporary! Please read the section in CONTRIBUTING about updating dependencies. + +source-repository-package + type: git + location: https://github.com/input-output-hk/cardano-api + --sha256: sha256-4xuBSgNHfRxFSrHJn7aziKwQmR9ctPjyLl08Oz6jOh4= + tag: a9cabb04b7e61ffc95ad8aa9756e3807ead0e754 + subdir: cardano-api diff --git a/cardano-cli/src/Cardano/CLI/Environment.hs b/cardano-cli/src/Cardano/CLI/Environment.hs index fd241a9a66..21a01a1ce8 100644 --- a/cardano-cli/src/Cardano/CLI/Environment.hs +++ b/cardano-cli/src/Cardano/CLI/Environment.hs @@ -4,18 +4,17 @@ -- | This module defines constants derived from the environment. module Cardano.CLI.Environment ( EnvCli (..) - , envCliAnyShelleyBasedEra - , envCliAnyShelleyToBabbageEra + , envCliAnyEon , getEnvCli , getEnvNetworkId , getEnvSocketPath ) where -import Cardano.Api (AnyCardanoEra (..), CardanoEra (..), EraInEon (..), NetworkId (..), - NetworkMagic (..), ShelleyBasedEra (..), ShelleyToBabbageEra (..), - forEraInEonMaybe) +import Cardano.Api (AnyCardanoEra (..), CardanoEra (..), Eon, EraInEon (..), + NetworkId (..), NetworkMagic (..), forEraInEonMaybe) +import Data.Typeable import Data.Word (Word32) import qualified System.Environment as IO import qualified System.IO as IO @@ -40,13 +39,8 @@ getEnvCli = do , envCliAnyCardanoEra = mCardanoEra } -envCliAnyShelleyBasedEra :: EnvCli -> Maybe (EraInEon ShelleyBasedEra) -envCliAnyShelleyBasedEra envCli = do - AnyCardanoEra era <- envCliAnyCardanoEra envCli - forEraInEonMaybe era EraInEon - -envCliAnyShelleyToBabbageEra :: EnvCli -> Maybe (EraInEon ShelleyToBabbageEra) -envCliAnyShelleyToBabbageEra envCli = do +envCliAnyEon :: Typeable eon => Eon eon => EnvCli -> Maybe (EraInEon eon) +envCliAnyEon envCli = do AnyCardanoEra era <- envCliAnyCardanoEra envCli forEraInEonMaybe era EraInEon diff --git a/cardano-cli/src/Cardano/CLI/EraBased/Commands.hs b/cardano-cli/src/Cardano/CLI/EraBased/Commands.hs index aa6711daed..c25844b8e1 100644 --- a/cardano-cli/src/Cardano/CLI/EraBased/Commands.hs +++ b/cardano-cli/src/Cardano/CLI/EraBased/Commands.hs @@ -20,7 +20,7 @@ import Cardano.CLI.EraBased.Commands.Key import Cardano.CLI.EraBased.Commands.Node import Cardano.CLI.EraBased.Commands.Query import Cardano.CLI.EraBased.Commands.StakeAddress -import Cardano.CLI.EraBased.Commands.StakePool +import Cardano.CLI.EraBased.Commands.StakePool hiding (sbe) import Cardano.CLI.EraBased.Commands.TextView import Cardano.CLI.EraBased.Commands.Transaction import Cardano.CLI.EraBased.Options.Address @@ -113,17 +113,18 @@ pAnyEraCommand envCli = ] pCmds :: ShelleyBasedEra era -> EnvCli -> Parser (Cmds era) -pCmds era envCli = +pCmds sbe' envCli = do + let cEra = toCardanoEra sbe' asum $ catMaybes - [ fmap AddressCmds <$> pAddressCmds (toCardanoEra era) envCli + [ fmap AddressCmds <$> pAddressCmds cEra envCli , fmap KeyCmds <$> pKeyCmds - , fmap GenesisCmds <$> pGenesisCmds (toCardanoEra era) envCli - , fmap GovernanceCmds <$> pGovernanceCmds (toCardanoEra era) + , fmap GenesisCmds <$> pGenesisCmds cEra envCli + , fmap GovernanceCmds <$> pGovernanceCmds cEra , fmap NodeCmds <$> pNodeCmds - , fmap QueryCmds <$> pQueryCmds (toCardanoEra era) envCli - , fmap StakeAddressCmds <$> pStakeAddressCmds (toCardanoEra era) envCli - , fmap StakePoolCmds <$> pStakePoolCmds (toCardanoEra era) envCli + , fmap QueryCmds <$> pQueryCmds cEra envCli + , fmap StakeAddressCmds <$> pStakeAddressCmds cEra envCli + , fmap StakePoolCmds <$> pStakePoolCmds cEra envCli , fmap TextViewCmds <$> pTextViewCmds - , fmap TransactionCmds <$> pTransactionCmds era envCli + , fmap TransactionCmds <$> pTransactionCmds sbe' envCli ] diff --git a/cardano-cli/src/Cardano/CLI/EraBased/Commands/Transaction.hs b/cardano-cli/src/Cardano/CLI/EraBased/Commands/Transaction.hs index 62e359db9b..5efe08f5c6 100644 --- a/cardano-cli/src/Cardano/CLI/EraBased/Commands/Transaction.hs +++ b/cardano-cli/src/Cardano/CLI/EraBased/Commands/Transaction.hs @@ -21,6 +21,7 @@ module Cardano.CLI.EraBased.Commands.Transaction ) where +import qualified Cardano.Api.Experimental as Exp import Cardano.Api.Ledger (Coin) import Cardano.Api.Shelley @@ -87,7 +88,7 @@ data TransactionBuildRawCmdArgs era = TransactionBuildRawCmdArgs -- | Like 'TransactionBuildRaw' but without the fee, and with a change output. data TransactionBuildCmdArgs era = TransactionBuildCmdArgs - { eon :: !(ShelleyBasedEra era) + { era :: !(Exp.Era era) , nodeSocketPath :: !SocketPath , consensusModeParams :: !ConsensusModeParams , networkId :: !NetworkId @@ -135,7 +136,7 @@ data TransactionBuildCmdArgs era = TransactionBuildCmdArgs -- | Like 'TransactionBuildCmd' but does not require explicit access to a running node data TransactionBuildEstimateCmdArgs era = TransactionBuildEstimateCmdArgs - { eon :: !(MaryEraOnwards era) + { era :: !(Exp.Era era) , mScriptValidity :: !(Maybe ScriptValidity) -- ^ Mark script as expected to pass or fail validation , shelleyWitnesses :: !Int diff --git a/cardano-cli/src/Cardano/CLI/EraBased/Options/Common.hs b/cardano-cli/src/Cardano/CLI/EraBased/Options/Common.hs index 1795b4b18b..7a1a95f2c2 100644 --- a/cardano-cli/src/Cardano/CLI/EraBased/Options/Common.hs +++ b/cardano-cli/src/Cardano/CLI/EraBased/Options/Common.hs @@ -16,8 +16,7 @@ import Cardano.Api import qualified Cardano.Api.Ledger as L import Cardano.Api.Shelley -import Cardano.CLI.Environment (EnvCli (..), envCliAnyShelleyBasedEra, - envCliAnyShelleyToBabbageEra) +import Cardano.CLI.Environment (EnvCli (..), envCliAnyEon) import Cardano.CLI.Parser import Cardano.CLI.Read import Cardano.CLI.Types.Common @@ -379,7 +378,7 @@ pAnyShelleyBasedEra envCli = , Opt.flag' (EraInEon ShelleyBasedEraConway) $ mconcat [Opt.long "conway-era", Opt.help "Specify the Conway era"] ] - , maybeToList $ pure <$> envCliAnyShelleyBasedEra envCli + , maybeToList $ pure <$> envCliAnyEon envCli , pure . pure $ EraInEon ShelleyBasedEraBabbage ] @@ -402,7 +401,7 @@ pAnyShelleyToBabbageEra envCli = , Opt.flag' (EraInEon ShelleyToBabbageEraBabbage) $ mconcat [Opt.long "babbage-era", Opt.help $ "Specify the Babbage era (default)" <> deprecationText] ] - , maybeToList $ pure <$> envCliAnyShelleyToBabbageEra envCli + , maybeToList $ pure <$> envCliAnyEon envCli , pure . pure $ EraInEon ShelleyToBabbageEraBabbage ] @@ -417,7 +416,7 @@ pShelleyBasedShelley envCli = , maybeToList $ fmap pure $ mfilter (== EraInEon ShelleyBasedEraShelley) $ - envCliAnyShelleyBasedEra envCli + envCliAnyEon envCli ] pShelleyBasedAllegra :: EnvCli -> Parser (EraInEon ShelleyBasedEra) @@ -431,7 +430,7 @@ pShelleyBasedAllegra envCli = , maybeToList $ fmap pure $ mfilter (== EraInEon ShelleyBasedEraAllegra) $ - envCliAnyShelleyBasedEra envCli + envCliAnyEon envCli ] pShelleyBasedMary :: EnvCli -> Parser (EraInEon ShelleyBasedEra) @@ -445,7 +444,7 @@ pShelleyBasedMary envCli = , maybeToList $ fmap pure $ mfilter (== EraInEon ShelleyBasedEraMary) $ - envCliAnyShelleyBasedEra envCli + envCliAnyEon envCli ] pShelleyBasedAlonzo :: EnvCli -> Parser (EraInEon ShelleyBasedEra) @@ -459,7 +458,7 @@ pShelleyBasedAlonzo envCli = , maybeToList $ fmap pure $ mfilter (== EraInEon ShelleyBasedEraAlonzo) $ - envCliAnyShelleyBasedEra envCli + envCliAnyEon envCli ] pShelleyBasedBabbage :: EnvCli -> Parser (EraInEon ShelleyBasedEra) @@ -473,7 +472,7 @@ pShelleyBasedBabbage envCli = , maybeToList $ fmap pure $ mfilter (== EraInEon ShelleyBasedEraBabbage) $ - envCliAnyShelleyBasedEra envCli + envCliAnyEon envCli ] pShelleyBasedConway :: EnvCli -> Parser (EraInEon ShelleyBasedEra) @@ -487,7 +486,7 @@ pShelleyBasedConway envCli = , maybeToList $ fmap pure $ mfilter (== EraInEon ShelleyBasedEraConway) $ - envCliAnyShelleyBasedEra envCli + envCliAnyEon envCli ] pFileOutDirection :: String -> String -> Parser (File a Out) diff --git a/cardano-cli/src/Cardano/CLI/EraBased/Options/Transaction.hs b/cardano-cli/src/Cardano/CLI/EraBased/Options/Transaction.hs index b398d1bd76..2c7013726c 100644 --- a/cardano-cli/src/Cardano/CLI/EraBased/Options/Transaction.hs +++ b/cardano-cli/src/Cardano/CLI/EraBased/Options/Transaction.hs @@ -10,9 +10,10 @@ module Cardano.CLI.EraBased.Options.Transaction where import Cardano.Api hiding (QueryInShelleyBasedEra (..)) +import qualified Cardano.Api.Experimental as Exp import Cardano.CLI.Environment (EnvCli (..)) -import Cardano.CLI.EraBased.Commands.Transaction +import Cardano.CLI.EraBased.Commands.Transaction hiding (era) import Cardano.CLI.EraBased.Options.Common import Cardano.CLI.Types.Common @@ -147,11 +148,13 @@ pScriptValidity = ] ] -pTransactionBuildCmd :: ShelleyBasedEra era -> EnvCli -> Maybe (Parser (TransactionCmds era)) -pTransactionBuildCmd era envCli = do +pTransactionBuildCmd + :: forall era. ShelleyBasedEra era -> EnvCli -> Maybe (Parser (TransactionCmds era)) +pTransactionBuildCmd sbe envCli = do + beo <- forEraMaybeEon (toCardanoEra sbe) pure $ subParser "build" $ - Opt.info (pCmd era) $ + Opt.info (pCmd beo) $ Opt.progDescDoc $ Just $ mconcat @@ -167,10 +170,10 @@ pTransactionBuildCmd era envCli = do ] ] where - pCmd :: ShelleyBasedEra era -> Parser (TransactionCmds era) - pCmd sbe = + pCmd :: BabbageEraOnwards era -> Parser (TransactionCmds era) + pCmd beo = do fmap TransactionBuildCmd $ - TransactionBuildCmdArgs sbe + TransactionBuildCmdArgs (Exp.babbageEraOnwardsToEra beo) <$> pSocketPath envCli <*> pConsensusModeParams <*> pNetworkId envCli @@ -204,8 +207,10 @@ pTransactionBuildCmd era envCli = do <*> pTxBuildOutputOptions -- | Estimate the transaction fees without access to a live node. -pTransactionBuildEstimateCmd :: MaryEraOnwards era -> EnvCli -> Maybe (Parser (TransactionCmds era)) -pTransactionBuildEstimateCmd era _envCli = do +pTransactionBuildEstimateCmd + :: forall era. MaryEraOnwards era -> EnvCli -> Maybe (Parser (TransactionCmds era)) +pTransactionBuildEstimateCmd eon' _envCli = do + era <- forEraMaybeEon (toCardanoEra eon') pure $ subParser "build-estimate" $ Opt.info (pCmd era) $ @@ -225,11 +230,11 @@ pTransactionBuildEstimateCmd era _envCli = do ] ] where - pCmd :: MaryEraOnwards era -> Parser (TransactionCmds era) - pCmd w = do - let sbe = maryEraOnwardsToShelleyBasedEra w + pCmd :: Exp.Era era -> Parser (TransactionCmds era) + pCmd era = do + let sbe = Exp.eraToSbe era fmap TransactionBuildEstimateCmd $ - TransactionBuildEstimateCmdArgs w + TransactionBuildEstimateCmdArgs era <$> optional pScriptValidity <*> pNumberOfShelleyKeyWitnesses <*> optional pNumberOfByronKeyWitnesses diff --git a/cardano-cli/src/Cardano/CLI/EraBased/Run/Transaction.hs b/cardano-cli/src/Cardano/CLI/EraBased/Run/Transaction.hs index 93e1b5dcb3..feac0f1f2c 100644 --- a/cardano-cli/src/Cardano/CLI/EraBased/Run/Transaction.hs +++ b/cardano-cli/src/Cardano/CLI/EraBased/Run/Transaction.hs @@ -36,6 +36,7 @@ where import Cardano.Api import Cardano.Api.Byron hiding (SomeByronSigningKey (..)) +import qualified Cardano.Api.Experimental as Exp import qualified Cardano.Api.Ledger as L import Cardano.Api.Shelley @@ -103,12 +104,11 @@ runTransactionCmds = \case -- runTransactionBuildCmd - :: () - => Cmd.TransactionBuildCmdArgs era + :: Cmd.TransactionBuildCmdArgs era -> ExceptT TxCmdError IO () runTransactionBuildCmd Cmd.TransactionBuildCmdArgs - { eon + { era , nodeSocketPath , consensusModeParams , networkId = networkId @@ -135,8 +135,9 @@ runTransactionBuildCmd , proposalFiles , treasuryDonation -- Maybe TxTreasuryDonation , buildOutputOptions - } = shelleyBasedEraConstraints eon $ do - let era = toCardanoEra eon + } = do + let eon = Exp.eraToSbe era + era' = toCardanoEra eon -- The user can specify an era prior to the era that the node is currently in. -- We cannot use the user specified era to construct a query against a node because it may differ @@ -159,7 +160,8 @@ runTransactionBuildCmd [ fmap (,mSwit) ( firstExceptT TxCmdReadTextViewFileError . newExceptT $ - readFileTextEnvelope AsCertificate (File certFile) + shelleyBasedEraConstraints eon $ + readFileTextEnvelope AsCertificate (File certFile) ) | (CertificateFile certFile, mSwit) <- certFilesAndMaybeScriptWits ] @@ -192,7 +194,7 @@ runTransactionBuildCmd inEonForEra (pure mempty) (\w -> firstExceptT TxCmdVoteError $ ExceptT (readVotingProceduresFiles w voteFiles)) - era + era' proposals <- newExceptT $ @@ -237,7 +239,7 @@ runTransactionBuildCmd (Just td, Just ctv) -> Just (ctv, td) -- We need to construct the txBodycontent outside of runTxBuild - BalancedTxBody txBodyContent balancedTxBody _ _ <- + BalancedTxBody txBodyContent unsignedTx@(Exp.UnsignedTx balancedTxBody) _ _ <- runTxBuild eon nodeSocketPath @@ -273,24 +275,24 @@ runTransactionBuildCmd pparams <- pure mTxProtocolParams & onNothing (left TxCmdProtocolParametersNotPresentInTxBody) executionUnitPrices <- - pure (getExecutionUnitPrices era pparams) & onNothing (left TxCmdPParamExecutionUnitsNotAvailable) + pure (getExecutionUnitPrices era' pparams) & onNothing (left TxCmdPParamExecutionUnitsNotAvailable) Refl <- - testEquality era nodeEra - & hoistMaybe (TxCmdTxNodeEraMismatchError $ NodeEraMismatchError era nodeEra) + testEquality era' nodeEra + & hoistMaybe (TxCmdTxNodeEraMismatchError $ NodeEraMismatchError era' nodeEra) scriptExecUnitsMap <- firstExceptT (TxCmdTxExecUnitsErr . AnyTxCmdTxExecUnitsErr) $ hoistEither $ - evaluateTransactionExecutionUnits - era + evaluateTransactionExecutionUnitsShelley + eon systemStart (toLedgerEpochInfo eraHistory) pparams txEraUtxo - balancedTxBody + (Exp.obtainCommonConstraints era balancedTxBody) - let mScriptWits = forEraInEon era [] $ \sbe -> collectTxBodyScriptWitnesses sbe txBodyContent + let mScriptWits = forEraInEon era' [] $ \sbe -> collectTxBodyScriptWitnesses sbe txBodyContent scriptCostOutput <- firstExceptT TxCmdPlutusScriptCostErr $ @@ -301,10 +303,10 @@ runTransactionBuildCmd mScriptWits scriptExecUnitsMap liftIO $ LBS.writeFile (unFile fp) $ encodePretty scriptCostOutput - OutputTxBodyOnly fpath -> - let noWitTx = makeSignedTransaction [] balancedTxBody - in lift (cardanoEraConstraints era $ writeTxFileTextEnvelopeCddl eon fpath noWitTx) - & onLeft (left . TxCmdWriteFileError) + OutputTxBodyOnly fpath -> do + let noWitTx = ShelleyTx eon $ Exp.obtainCommonConstraints era $ Exp.signTx era [] [] unsignedTx + lift (writeTxFileTextEnvelopeCddl eon fpath noWitTx) + & onLeft (left . TxCmdWriteFileError) runTransactionBuildEstimateCmd :: () @@ -312,7 +314,7 @@ runTransactionBuildEstimateCmd -> ExceptT TxCmdError IO () runTransactionBuildEstimateCmd -- TODO change type Cmd.TransactionBuildEstimateCmdArgs - { eon + { era , mScriptValidity , shelleyWitnesses , mByronWitnesses @@ -341,7 +343,9 @@ runTransactionBuildEstimateCmd -- TODO change type , currentTreasuryValueAndDonation , txBodyOutFile } = do - let sbe = maryEraOnwardsToShelleyBasedEra eon + let sbe = Exp.eraToSbe era + meo = babbageEraOnwardsToMaryEraOnwards $ Exp.eraToBabbageEraOnwards era + ledgerPParams <- firstExceptT TxCmdProtocolParamsError $ readProtocolParameters sbe protocolParamsFile inputsAndMaybeScriptWits <- @@ -378,7 +382,7 @@ runTransactionBuildEstimateCmd -- TODO change type txOuts <- mapM (toTxOutInAnyEra sbe) txouts -- the same collateral input can be used for several plutus scripts - let filteredTxinsc = toList @(Set _) $ fromList txInsCollateral + let filteredTxinsc = nubOrd txInsCollateral -- Conway related votingProceduresAndMaybeScriptWits <- @@ -442,11 +446,11 @@ runTransactionBuildEstimateCmd -- TODO change type collectTxBodyScriptWitnesses sbe txBodyContent ] - BalancedTxBody _ balancedTxBody _ _ <- + BalancedTxBody _ unsignedTx _ _ <- hoistEither $ first TxCmdFeeEstimationError $ estimateBalancedTxBody - eon + meo txBodyContent ledgerPParams poolsToDeregister @@ -460,7 +464,7 @@ runTransactionBuildEstimateCmd -- TODO change type (anyAddressInShelleyBasedEra sbe changeAddr) totalUTxOValue - let noWitTx = makeSignedTransaction [] balancedTxBody + let noWitTx = ShelleyTx sbe $ Exp.obtainCommonConstraints era $ Exp.signTx era [] [] unsignedTx lift (writeTxFileTextEnvelopeCddl sbe txBodyOutFile noWitTx) & onLeft (left . TxCmdWriteFileError) @@ -759,7 +763,7 @@ runTxBuildRaw proposals mCurrentTreasuryValueAndDonation - first TxCmdTxBodyError $ createAndValidateTransactionBody sbe txBodyContent + first TxCmdTxBodyError $ createTransactionBody sbe txBodyContent constructTxBodyContent :: forall era @@ -1330,7 +1334,7 @@ createTxMintValue -> (Value, [ScriptWitness WitCtxMint era]) -> Either TxCmdError (TxMintValue BuildTx era) createTxMintValue era (val, scriptWitnesses) = - if List.null (valueToList val) && List.null scriptWitnesses + if List.null (toList val) && List.null scriptWitnesses then return TxMintNone else do caseShelleyToAllegraOrMaryEraOnwards @@ -1339,7 +1343,7 @@ createTxMintValue era (val, scriptWitnesses) = -- The set of policy ids for which we need witnesses: let witnessesNeededSet :: Set PolicyId witnessesNeededSet = - fromList [pid | (AssetId pid _, _) <- valueToList val] + fromList [pid | (AssetId pid _, _) <- toList val] let witnessesProvidedMap :: Map PolicyId (ScriptWitness WitCtxMint era) witnessesProvidedMap = fromList $ gatherMintingWitnesses scriptWitnesses diff --git a/cardano-cli/src/Cardano/CLI/Legacy/Commands/Transaction.hs b/cardano-cli/src/Cardano/CLI/Legacy/Commands/Transaction.hs index 8c8684cc9c..e84f72b4d1 100644 --- a/cardano-cli/src/Cardano/CLI/Legacy/Commands/Transaction.hs +++ b/cardano-cli/src/Cardano/CLI/Legacy/Commands/Transaction.hs @@ -7,6 +7,7 @@ module Cardano.CLI.Legacy.Commands.Transaction ) where +import qualified Cardano.Api.Experimental as Exp import Cardano.Api.Ledger (Coin) import Cardano.Api.Shelley @@ -54,7 +55,7 @@ data LegacyTransactionCmds | -- | Like 'TransactionBuildRaw' but without the fee, and with a change output. TransactionBuildCmd SocketPath - (EraInEon ShelleyBasedEra) + (EraInEon Exp.Era) ConsensusModeParams NetworkId (Maybe ScriptValidity) diff --git a/cardano-cli/src/Cardano/CLI/Legacy/Options.hs b/cardano-cli/src/Cardano/CLI/Legacy/Options.hs index 4fa5d58e05..b752a71aca 100644 --- a/cardano-cli/src/Cardano/CLI/Legacy/Options.hs +++ b/cardano-cli/src/Cardano/CLI/Legacy/Options.hs @@ -22,6 +22,7 @@ module Cardano.CLI.Legacy.Options where import Cardano.Api hiding (QueryInShelleyBasedEra (..)) +import qualified Cardano.Api.Experimental as Exp import Cardano.Api.Ledger (Coin (..)) import Cardano.Api.Shelley hiding (QueryInShelleyBasedEra (..)) @@ -349,7 +350,7 @@ pTransaction envCli = pTransactionBuild = TransactionBuildCmd <$> pSocketPath envCli - <*> pLegacyShelleyBasedEra envCli + <*> pEra envCli <*> pConsensusModeParams <*> pNetworkId envCli <*> optional pScriptValidity @@ -1365,6 +1366,26 @@ pLegacyShelleyBasedEra envCli = , Opt.help $ "Specify the Babbage era (default)" <> deprecationText ] ] - , maybeToList $ pure <$> envCliAnyShelleyBasedEra envCli + , maybeToList $ pure <$> envCliAnyEon envCli , pure . pure $ EraInEon ShelleyBasedEraBabbage ] + +pEra :: EnvCli -> Parser (EraInEon Exp.Era) +pEra envCli = + asum $ + mconcat + [ + [ Opt.flag' (EraInEon Exp.BabbageEra) $ + mconcat + [ Opt.long "babbage-era" + , Opt.help "Specify the Babbage era (default)" + ] + , Opt.flag' (EraInEon Exp.ConwayEra) $ + mconcat + [ Opt.long "conway-era" + , Opt.help "Specify the Conway era" + ] + ] + , maybeToList $ pure <$> envCliAnyEon envCli + , pure $ pure (EraInEon Exp.BabbageEra) + ] diff --git a/cardano-cli/src/Cardano/CLI/Legacy/Run/Transaction.hs b/cardano-cli/src/Cardano/CLI/Legacy/Run/Transaction.hs index 11cb62998b..07a5889922 100644 --- a/cardano-cli/src/Cardano/CLI/Legacy/Run/Transaction.hs +++ b/cardano-cli/src/Cardano/CLI/Legacy/Run/Transaction.hs @@ -12,6 +12,7 @@ where import Cardano.Api import qualified Cardano.Api.Byron as Api +import qualified Cardano.Api.Experimental as Exp import Cardano.Api.Ledger (Coin) import qualified Cardano.CLI.EraBased.Commands.Transaction as Cmd @@ -168,7 +169,7 @@ runLegacyTransactionCmds = \case runLegacyTransactionBuildCmd :: () => SocketPath - -> EraInEon ShelleyBasedEra + -> EraInEon Exp.Era -> ConsensusModeParams -> NetworkId -> Maybe ScriptValidity @@ -207,7 +208,7 @@ runLegacyTransactionBuildCmd -> ExceptT TxCmdError IO () runLegacyTransactionBuildCmd socketPath - (EraInEon sbe) + (EraInEon era) consensusModeParams nid mScriptValidity @@ -233,6 +234,7 @@ runLegacyTransactionBuildCmd proposalFiles mTreasuryDonation outputOptions = do + let sbe = Exp.eraToSbe era mUpdateProposalFile <- validateUpdateProposalFile (toCardanoEra sbe) mUpdateProposal & hoistEither @@ -242,7 +244,7 @@ runLegacyTransactionBuildCmd runTransactionBuildCmd ( Cmd.TransactionBuildCmdArgs - sbe + era socketPath consensusModeParams nid diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help.cli index a8f8ca908e..8a91dd901d 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help.cli @@ -823,7 +823,6 @@ Usage: cardano-cli shelley text-view decode-cbor --in-file FILE Usage: cardano-cli shelley transaction ( build-raw - | build | sign | witness | assemble @@ -966,130 +965,6 @@ Usage: cardano-cli shelley transaction build-raw Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m -Usage: cardano-cli shelley transaction build --socket-path SOCKET_PATH - [--cardano-mode - [--epoch-slots SLOTS]] - ( --mainnet - | --testnet-magic NATURAL - ) - [ --script-valid - | --script-invalid - ] - [--witness-override WORD] - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - )] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-total-collateral INTEGER] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - ( --out-file FILE - | --calculate-plutus-script-cost FILE - ) - - Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - Usage: cardano-cli shelley transaction sign ( --tx-body-file FILE | --tx-file FILE @@ -2018,7 +1893,6 @@ Usage: cardano-cli allegra text-view decode-cbor --in-file FILE Usage: cardano-cli allegra transaction ( build-raw - | build | sign | witness | assemble @@ -2161,130 +2035,6 @@ Usage: cardano-cli allegra transaction build-raw Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m -Usage: cardano-cli allegra transaction build --socket-path SOCKET_PATH - [--cardano-mode - [--epoch-slots SLOTS]] - ( --mainnet - | --testnet-magic NATURAL - ) - [ --script-valid - | --script-invalid - ] - [--witness-override WORD] - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - )] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-total-collateral INTEGER] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - ( --out-file FILE - | --calculate-plutus-script-cost FILE - ) - - Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - Usage: cardano-cli allegra transaction sign ( --tx-body-file FILE | --tx-file FILE @@ -3204,8 +2954,6 @@ Usage: cardano-cli mary text-view decode-cbor --in-file FILE [--out-file FILE] Usage: cardano-cli mary transaction ( build-raw - | build - | build-estimate | sign | witness | assemble @@ -3348,260 +3096,6 @@ Usage: cardano-cli mary transaction build-raw Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m -Usage: cardano-cli mary transaction build --socket-path SOCKET_PATH - [--cardano-mode - [--epoch-slots SLOTS]] - ( --mainnet - | --testnet-magic NATURAL - ) - [--script-valid | --script-invalid] - [--witness-override WORD] - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - )] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-total-collateral INTEGER] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - ( --out-file FILE - | --calculate-plutus-script-cost FILE - ) - - Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - -Usage: cardano-cli mary transaction build-estimate - [ --script-valid - | --script-invalid - ] - --shelley-key-witnesses INT - [--byron-key-witnesses Int] - --protocol-params-file FILE - --total-utxo-value VALUE - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - --spending-reference-tx-in-execution-units (INT, INT) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - ) - --tx-in-execution-units (INT, INT)] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ - ( --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ) - --mint-execution-units (INT, INT)] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --mint-reference-tx-in-execution-units (INT, INT) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ - ( --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ) - --certificate-execution-units (INT, INT)] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - --certificate-reference-tx-in-execution-units (INT, INT) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ - ( --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ) - --withdrawal-execution-units (INT, INT)] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - --withdrawal-reference-tx-in-execution-units (INT, INT) - ]] - [--tx-total-collateral INTEGER] - [--reference-script-size NATURAL] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - --out-file FILE - - Build a balanced transaction without access to a live node (automatically estimates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - Usage: cardano-cli mary transaction sign (--tx-body-file FILE | --tx-file FILE) [--signing-key-file FILE [--address STRING]] @@ -4526,8 +4020,6 @@ Usage: cardano-cli alonzo text-view decode-cbor --in-file FILE [--out-file FILE] Usage: cardano-cli alonzo transaction ( build-raw - | build - | build-estimate | sign | witness | assemble @@ -4670,262 +4162,6 @@ Usage: cardano-cli alonzo transaction build-raw Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m -Usage: cardano-cli alonzo transaction build --socket-path SOCKET_PATH - [--cardano-mode - [--epoch-slots SLOTS]] - ( --mainnet - | --testnet-magic NATURAL - ) - [ --script-valid - | --script-invalid - ] - [--witness-override WORD] - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - )] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-total-collateral INTEGER] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - ( --out-file FILE - | --calculate-plutus-script-cost FILE - ) - - Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - -Usage: cardano-cli alonzo transaction build-estimate - [ --script-valid - | --script-invalid - ] - --shelley-key-witnesses INT - [--byron-key-witnesses Int] - --protocol-params-file FILE - --total-utxo-value VALUE - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - --spending-reference-tx-in-execution-units (INT, INT) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - ) - --tx-in-execution-units (INT, INT)] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ - ( --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ) - --mint-execution-units (INT, INT)] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --mint-reference-tx-in-execution-units (INT, INT) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ - ( --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ) - --certificate-execution-units (INT, INT)] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - --certificate-reference-tx-in-execution-units (INT, INT) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ - ( --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ) - --withdrawal-execution-units (INT, INT)] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - --withdrawal-reference-tx-in-execution-units (INT, INT) - ]] - [--tx-total-collateral INTEGER] - [--reference-script-size NATURAL] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - --out-file FILE - - Build a balanced transaction without access to a live node (automatically estimates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - Usage: cardano-cli alonzo transaction sign ( --tx-body-file FILE | --tx-file FILE @@ -10460,12 +9696,7 @@ Usage: cardano-cli legacy transaction build-raw Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m Usage: cardano-cli legacy transaction build --socket-path SOCKET_PATH - [ --shelley-era - | --allegra-era - | --mary-era - | --alonzo-era - | --babbage-era - ] + [--babbage-era | --conway-era] [--cardano-mode [--epoch-slots SLOTS]] ( --mainnet @@ -11735,12 +10966,7 @@ Usage: cardano-cli transaction build-raw Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m Usage: cardano-cli transaction build --socket-path SOCKET_PATH - [ --shelley-era - | --allegra-era - | --mary-era - | --alonzo-era - | --babbage-era - ] + [--babbage-era | --conway-era] [--cardano-mode [--epoch-slots SLOTS]] (--mainnet | --testnet-magic NATURAL) [--script-valid | --script-invalid] diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_transaction.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_transaction.cli index 7bfcf31935..dd81c9cf39 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_transaction.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_transaction.cli @@ -1,6 +1,5 @@ Usage: cardano-cli allegra transaction ( build-raw - | build | sign | witness | assemble @@ -21,9 +20,6 @@ Available options: Available commands: build-raw Build a transaction (low-level, inconvenient) - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - build Build a balanced transaction (automatically calculates fees) - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m sign Sign a transaction witness Create a transaction witness diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_transaction_build.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_transaction_build.cli deleted file mode 100644 index 8951ece895..0000000000 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_transaction_build.cli +++ /dev/null @@ -1,393 +0,0 @@ -Usage: cardano-cli allegra transaction build --socket-path SOCKET_PATH - [--cardano-mode - [--epoch-slots SLOTS]] - ( --mainnet - | --testnet-magic NATURAL - ) - [ --script-valid - | --script-invalid - ] - [--witness-override WORD] - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - )] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-total-collateral INTEGER] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - ( --out-file FILE - | --calculate-plutus-script-cost FILE - ) - - Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - -Available options: - --socket-path SOCKET_PATH - Path to the node socket. This overrides the - CARDANO_NODE_SOCKET_PATH environment variable. The - argument is optional if CARDANO_NODE_SOCKET_PATH is - defined and mandatory otherwise. - --cardano-mode For talking to a node running in full Cardano mode - (default). - --epoch-slots SLOTS The number of slots per epoch for the Byron era. - (default: 21600) - --mainnet Use the mainnet magic id. This overrides the - CARDANO_NODE_NETWORK_ID environment variable - --testnet-magic NATURAL Specify a testnet magic id. This overrides the - CARDANO_NODE_NETWORK_ID environment variable - --script-valid Assertion that the script is valid. (default) - --script-invalid Assertion that the script is invalid. If a - transaction is submitted with such a script, the - script will fail and the collateral will be taken. - --witness-override WORD Specify and override the number of witnesses the - transaction requires. - --tx-in TX-IN TxId#TxIx - --spending-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --spending-plutus-script-v2 - Specify a plutus script v2 reference script. - --spending-plutus-script-v3 - Specify a plutus script v3 reference script. - --spending-reference-tx-in-datum-cbor-file CBOR_FILE - The script datum file. The file has to be in CBOR - format. - --spending-reference-tx-in-datum-file JSON_FILE - The script datum file. The file must follow the - detailed JSON schema for script data. - --spending-reference-tx-in-datum-value JSON_VALUE - The script datum. There is no schema: (almost) any - JSON value is supported, including top-level strings - and numbers. - --spending-reference-tx-in-inline-datum-present - Inline datum present at transaction input. - --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --spending-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --spending-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --simple-script-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a simple reference script attached. - --tx-in-script-file FILE The file containing the script to witness the - spending of the transaction input. - --tx-in-datum-cbor-file CBOR_FILE - The script datum file. The file has to be in CBOR - format. - --tx-in-datum-file JSON_FILE - The script datum file. The file must follow the - detailed JSON schema for script data. - --tx-in-datum-value JSON_VALUE - The script datum. There is no schema: (almost) any - JSON value is supported, including top-level strings - and numbers. - --tx-in-inline-datum-present - Inline datum present at transaction input. - --tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --read-only-tx-in-reference TX-IN - Specify a read only reference input. This reference - input is not witnessing anything it is simply - provided in the plutus script context. - --required-signer FILE Input filepath of the signing key (zero or more) - whose signature is required. - --required-signer-hash HASH - Hash of the verification key (zero or more) whose - signature is required. - --tx-in-collateral TX-IN TxId#TxIx - --tx-out-return-collateral ADDRESS VALUE - The transaction output as ADDRESS VALUE where ADDRESS - is the Bech32-encoded address followed by the value - in Lovelace. In the situation where your collateral - txin over collateralizes the transaction, you can - optionally specify a tx out of your choosing to - return the excess Lovelace. - --tx-total-collateral INTEGER - The total amount of collateral that will be collected - as fees in the event of a Plutus script failure. Must - be used in conjuction with - "--tx-out-return-collateral". - --tx-out ADDRESS VALUE The transaction output as ADDRESS VALUE where ADDRESS - is the Bech32-encoded address followed by the value - in the multi-asset syntax (including simply - Lovelace). - --tx-out-datum-hash HASH The script datum hash for this tx output, as the raw - datum hash (in hex). - --tx-out-datum-hash-cbor-file CBOR_FILE - The script datum hash for this tx output, by hashing - the script datum in the file. The file has to be in - CBOR format. - --tx-out-datum-hash-file JSON_FILE - The script datum hash for this tx output, by hashing - the script datum in the file. The file must follow - the detailed JSON schema for script data. - --tx-out-datum-hash-value JSON_VALUE - The script datum hash for this tx output, by hashing - the script datum given here. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --tx-out-datum-embed-cbor-file CBOR_FILE - The script datum to embed in the tx for this output, - in the given file. The file has to be in CBOR format. - --tx-out-datum-embed-file JSON_FILE - The script datum to embed in the tx for this output, - in the given file. The file must follow the detailed - JSON schema for script data. - --tx-out-datum-embed-value JSON_VALUE - The script datum to embed in the tx for this output, - given here. There is no schema: (almost) any JSON - value is supported, including top-level strings and - numbers. - --tx-out-inline-datum-cbor-file CBOR_FILE - The script datum to embed in the tx output as an - inline datum, in the given file. The file has to be - in CBOR format. - --tx-out-inline-datum-file JSON_FILE - The script datum to embed in the tx output as an - inline datum, in the given file. The file must follow - the detailed JSON schema for script data. - --tx-out-inline-datum-value JSON_VALUE - The script datum to embed in the tx output as an - inline datum, given here. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --tx-out-reference-script-file FILE - Reference script input file. - --change-address ADDRESS Address where ADA in excess of the tx fee will go to. - --mint VALUE Mint multi-asset value(s) with the multi-asset cli - syntax. You must specify a script witness. - --mint-script-file FILE The file containing the script to witness the minting - of assets for a particular policy Id. - --mint-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --mint-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --mint-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --simple-minting-script-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a simple reference script attached. - --policy-id HASH Policy id of minting script. - --mint-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --mint-plutus-script-v2 Specify a plutus script v2 reference script. - --mint-plutus-script-v3 Specify a plutus script v3 reference script. - --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --mint-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --mint-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --policy-id HASH Policy id of minting script. - --invalid-before SLOT Time that transaction is valid from (in slots). - --invalid-hereafter SLOT Time that transaction is valid until (in slots). - --certificate-file FILE Filepath of the certificate. This encompasses all - types of certificates (stake pool certificates, stake - key certificates etc). Optionally specify a script - witness. - --certificate-script-file FILE - The file containing the script to witness the use of - the certificate. - --certificate-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --certificate-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --certificate-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --certificate-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --certificate-plutus-script-v2 - Specify a plutus script v2 reference script. - --certificate-plutus-script-v3 - Specify a plutus script v3 reference script. - --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --certificate-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --certificate-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --withdrawal WITHDRAWAL The reward withdrawal as StakeAddress+Lovelace where - StakeAddress is the Bech32-encoded stake address - followed by the amount in Lovelace. Optionally - specify a script witness. - --withdrawal-script-file FILE - The file containing the script to witness the - withdrawal of rewards. - --withdrawal-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --withdrawal-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --withdrawal-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --withdrawal-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --withdrawal-plutus-script-v2 - Specify a plutus script v2 reference script. - --withdrawal-plutus-script-v3 - Specify a plutus script v3 reference script. - --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --withdrawal-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --json-metadata-no-schema - Use the "no schema" conversion from JSON to tx - metadata (default). - --json-metadata-detailed-schema - Use the "detailed schema" conversion from JSON to tx - metadata. - --auxiliary-script-file FILE - Filepath of auxiliary script(s) - --metadata-json-file FILE - Filepath of the metadata file, in JSON format. - --metadata-cbor-file FILE - Filepath of the metadata, in raw CBOR format. - --update-proposal-file FILE - Filepath of the update proposal. - --out-file FILE Output filepath of the JSON TxBody. - --calculate-plutus-script-cost FILE - (File () Out) filepath of the script cost - information. - -h,--help Show this help text diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_transaction.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_transaction.cli index f0b098886f..7d9ae4b55d 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_transaction.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_transaction.cli @@ -1,7 +1,5 @@ Usage: cardano-cli alonzo transaction ( build-raw - | build - | build-estimate | sign | witness | assemble @@ -22,12 +20,6 @@ Available options: Available commands: build-raw Build a transaction (low-level, inconvenient) - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - build Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - build-estimate Build a balanced transaction without access to a live node (automatically estimates fees) - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m sign Sign a transaction witness Create a transaction witness diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_transaction_build.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_transaction_build.cli deleted file mode 100644 index d7dfecbb77..0000000000 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_transaction_build.cli +++ /dev/null @@ -1,393 +0,0 @@ -Usage: cardano-cli alonzo transaction build --socket-path SOCKET_PATH - [--cardano-mode - [--epoch-slots SLOTS]] - ( --mainnet - | --testnet-magic NATURAL - ) - [ --script-valid - | --script-invalid - ] - [--witness-override WORD] - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - )] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-total-collateral INTEGER] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - ( --out-file FILE - | --calculate-plutus-script-cost FILE - ) - - Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - -Available options: - --socket-path SOCKET_PATH - Path to the node socket. This overrides the - CARDANO_NODE_SOCKET_PATH environment variable. The - argument is optional if CARDANO_NODE_SOCKET_PATH is - defined and mandatory otherwise. - --cardano-mode For talking to a node running in full Cardano mode - (default). - --epoch-slots SLOTS The number of slots per epoch for the Byron era. - (default: 21600) - --mainnet Use the mainnet magic id. This overrides the - CARDANO_NODE_NETWORK_ID environment variable - --testnet-magic NATURAL Specify a testnet magic id. This overrides the - CARDANO_NODE_NETWORK_ID environment variable - --script-valid Assertion that the script is valid. (default) - --script-invalid Assertion that the script is invalid. If a - transaction is submitted with such a script, the - script will fail and the collateral will be taken. - --witness-override WORD Specify and override the number of witnesses the - transaction requires. - --tx-in TX-IN TxId#TxIx - --spending-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --spending-plutus-script-v2 - Specify a plutus script v2 reference script. - --spending-plutus-script-v3 - Specify a plutus script v3 reference script. - --spending-reference-tx-in-datum-cbor-file CBOR_FILE - The script datum file. The file has to be in CBOR - format. - --spending-reference-tx-in-datum-file JSON_FILE - The script datum file. The file must follow the - detailed JSON schema for script data. - --spending-reference-tx-in-datum-value JSON_VALUE - The script datum. There is no schema: (almost) any - JSON value is supported, including top-level strings - and numbers. - --spending-reference-tx-in-inline-datum-present - Inline datum present at transaction input. - --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --spending-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --spending-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --simple-script-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a simple reference script attached. - --tx-in-script-file FILE The file containing the script to witness the - spending of the transaction input. - --tx-in-datum-cbor-file CBOR_FILE - The script datum file. The file has to be in CBOR - format. - --tx-in-datum-file JSON_FILE - The script datum file. The file must follow the - detailed JSON schema for script data. - --tx-in-datum-value JSON_VALUE - The script datum. There is no schema: (almost) any - JSON value is supported, including top-level strings - and numbers. - --tx-in-inline-datum-present - Inline datum present at transaction input. - --tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --read-only-tx-in-reference TX-IN - Specify a read only reference input. This reference - input is not witnessing anything it is simply - provided in the plutus script context. - --required-signer FILE Input filepath of the signing key (zero or more) - whose signature is required. - --required-signer-hash HASH - Hash of the verification key (zero or more) whose - signature is required. - --tx-in-collateral TX-IN TxId#TxIx - --tx-out-return-collateral ADDRESS VALUE - The transaction output as ADDRESS VALUE where ADDRESS - is the Bech32-encoded address followed by the value - in Lovelace. In the situation where your collateral - txin over collateralizes the transaction, you can - optionally specify a tx out of your choosing to - return the excess Lovelace. - --tx-total-collateral INTEGER - The total amount of collateral that will be collected - as fees in the event of a Plutus script failure. Must - be used in conjuction with - "--tx-out-return-collateral". - --tx-out ADDRESS VALUE The transaction output as ADDRESS VALUE where ADDRESS - is the Bech32-encoded address followed by the value - in the multi-asset syntax (including simply - Lovelace). - --tx-out-datum-hash HASH The script datum hash for this tx output, as the raw - datum hash (in hex). - --tx-out-datum-hash-cbor-file CBOR_FILE - The script datum hash for this tx output, by hashing - the script datum in the file. The file has to be in - CBOR format. - --tx-out-datum-hash-file JSON_FILE - The script datum hash for this tx output, by hashing - the script datum in the file. The file must follow - the detailed JSON schema for script data. - --tx-out-datum-hash-value JSON_VALUE - The script datum hash for this tx output, by hashing - the script datum given here. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --tx-out-datum-embed-cbor-file CBOR_FILE - The script datum to embed in the tx for this output, - in the given file. The file has to be in CBOR format. - --tx-out-datum-embed-file JSON_FILE - The script datum to embed in the tx for this output, - in the given file. The file must follow the detailed - JSON schema for script data. - --tx-out-datum-embed-value JSON_VALUE - The script datum to embed in the tx for this output, - given here. There is no schema: (almost) any JSON - value is supported, including top-level strings and - numbers. - --tx-out-inline-datum-cbor-file CBOR_FILE - The script datum to embed in the tx output as an - inline datum, in the given file. The file has to be - in CBOR format. - --tx-out-inline-datum-file JSON_FILE - The script datum to embed in the tx output as an - inline datum, in the given file. The file must follow - the detailed JSON schema for script data. - --tx-out-inline-datum-value JSON_VALUE - The script datum to embed in the tx output as an - inline datum, given here. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --tx-out-reference-script-file FILE - Reference script input file. - --change-address ADDRESS Address where ADA in excess of the tx fee will go to. - --mint VALUE Mint multi-asset value(s) with the multi-asset cli - syntax. You must specify a script witness. - --mint-script-file FILE The file containing the script to witness the minting - of assets for a particular policy Id. - --mint-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --mint-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --mint-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --simple-minting-script-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a simple reference script attached. - --policy-id HASH Policy id of minting script. - --mint-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --mint-plutus-script-v2 Specify a plutus script v2 reference script. - --mint-plutus-script-v3 Specify a plutus script v3 reference script. - --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --mint-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --mint-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --policy-id HASH Policy id of minting script. - --invalid-before SLOT Time that transaction is valid from (in slots). - --invalid-hereafter SLOT Time that transaction is valid until (in slots). - --certificate-file FILE Filepath of the certificate. This encompasses all - types of certificates (stake pool certificates, stake - key certificates etc). Optionally specify a script - witness. - --certificate-script-file FILE - The file containing the script to witness the use of - the certificate. - --certificate-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --certificate-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --certificate-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --certificate-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --certificate-plutus-script-v2 - Specify a plutus script v2 reference script. - --certificate-plutus-script-v3 - Specify a plutus script v3 reference script. - --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --certificate-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --certificate-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --withdrawal WITHDRAWAL The reward withdrawal as StakeAddress+Lovelace where - StakeAddress is the Bech32-encoded stake address - followed by the amount in Lovelace. Optionally - specify a script witness. - --withdrawal-script-file FILE - The file containing the script to witness the - withdrawal of rewards. - --withdrawal-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --withdrawal-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --withdrawal-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --withdrawal-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --withdrawal-plutus-script-v2 - Specify a plutus script v2 reference script. - --withdrawal-plutus-script-v3 - Specify a plutus script v3 reference script. - --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --withdrawal-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --json-metadata-no-schema - Use the "no schema" conversion from JSON to tx - metadata (default). - --json-metadata-detailed-schema - Use the "detailed schema" conversion from JSON to tx - metadata. - --auxiliary-script-file FILE - Filepath of auxiliary script(s) - --metadata-json-file FILE - Filepath of the metadata file, in JSON format. - --metadata-cbor-file FILE - Filepath of the metadata, in raw CBOR format. - --update-proposal-file FILE - Filepath of the update proposal. - --out-file FILE Output filepath of the JSON TxBody. - --calculate-plutus-script-cost FILE - (File () Out) filepath of the script cost - information. - -h,--help Show this help text diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/legacy_transaction_build.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/legacy_transaction_build.cli index 8d6acc377e..b4ec222434 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/legacy_transaction_build.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/legacy_transaction_build.cli @@ -1,10 +1,5 @@ Usage: cardano-cli legacy transaction build --socket-path SOCKET_PATH - [ --shelley-era - | --allegra-era - | --mary-era - | --alonzo-era - | --babbage-era - ] + [--babbage-era | --conway-era] [--cardano-mode [--epoch-slots SLOTS]] ( --mainnet @@ -161,16 +156,8 @@ Available options: CARDANO_NODE_SOCKET_PATH environment variable. The argument is optional if CARDANO_NODE_SOCKET_PATH is defined and mandatory otherwise. - --shelley-era Specify the Shelley era - DEPRECATED - will be - removed in the future - --allegra-era Specify the Allegra era - DEPRECATED - will be - removed in the future - --mary-era Specify the Mary era - DEPRECATED - will be removed - in the future - --alonzo-era Specify the Alonzo era - DEPRECATED - will be removed - in the future - --babbage-era Specify the Babbage era (default) - DEPRECATED - will - be removed in the future + --babbage-era Specify the Babbage era (default) + --conway-era Specify the Conway era --cardano-mode For talking to a node running in full Cardano mode (default). --epoch-slots SLOTS The number of slots per epoch for the Byron era. diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_transaction.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_transaction.cli index 636ab23334..5e34d35c91 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_transaction.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_transaction.cli @@ -1,7 +1,5 @@ Usage: cardano-cli mary transaction ( build-raw - | build - | build-estimate | sign | witness | assemble @@ -22,12 +20,6 @@ Available options: Available commands: build-raw Build a transaction (low-level, inconvenient) - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - build Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - build-estimate Build a balanced transaction without access to a live node (automatically estimates fees) - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m sign Sign a transaction witness Create a transaction witness diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_transaction_build.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_transaction_build.cli deleted file mode 100644 index dab32df48f..0000000000 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_transaction_build.cli +++ /dev/null @@ -1,391 +0,0 @@ -Usage: cardano-cli mary transaction build --socket-path SOCKET_PATH - [--cardano-mode - [--epoch-slots SLOTS]] - ( --mainnet - | --testnet-magic NATURAL - ) - [--script-valid | --script-invalid] - [--witness-override WORD] - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - )] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-total-collateral INTEGER] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - ( --out-file FILE - | --calculate-plutus-script-cost FILE - ) - - Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - -Available options: - --socket-path SOCKET_PATH - Path to the node socket. This overrides the - CARDANO_NODE_SOCKET_PATH environment variable. The - argument is optional if CARDANO_NODE_SOCKET_PATH is - defined and mandatory otherwise. - --cardano-mode For talking to a node running in full Cardano mode - (default). - --epoch-slots SLOTS The number of slots per epoch for the Byron era. - (default: 21600) - --mainnet Use the mainnet magic id. This overrides the - CARDANO_NODE_NETWORK_ID environment variable - --testnet-magic NATURAL Specify a testnet magic id. This overrides the - CARDANO_NODE_NETWORK_ID environment variable - --script-valid Assertion that the script is valid. (default) - --script-invalid Assertion that the script is invalid. If a - transaction is submitted with such a script, the - script will fail and the collateral will be taken. - --witness-override WORD Specify and override the number of witnesses the - transaction requires. - --tx-in TX-IN TxId#TxIx - --spending-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --spending-plutus-script-v2 - Specify a plutus script v2 reference script. - --spending-plutus-script-v3 - Specify a plutus script v3 reference script. - --spending-reference-tx-in-datum-cbor-file CBOR_FILE - The script datum file. The file has to be in CBOR - format. - --spending-reference-tx-in-datum-file JSON_FILE - The script datum file. The file must follow the - detailed JSON schema for script data. - --spending-reference-tx-in-datum-value JSON_VALUE - The script datum. There is no schema: (almost) any - JSON value is supported, including top-level strings - and numbers. - --spending-reference-tx-in-inline-datum-present - Inline datum present at transaction input. - --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --spending-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --spending-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --simple-script-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a simple reference script attached. - --tx-in-script-file FILE The file containing the script to witness the - spending of the transaction input. - --tx-in-datum-cbor-file CBOR_FILE - The script datum file. The file has to be in CBOR - format. - --tx-in-datum-file JSON_FILE - The script datum file. The file must follow the - detailed JSON schema for script data. - --tx-in-datum-value JSON_VALUE - The script datum. There is no schema: (almost) any - JSON value is supported, including top-level strings - and numbers. - --tx-in-inline-datum-present - Inline datum present at transaction input. - --tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --read-only-tx-in-reference TX-IN - Specify a read only reference input. This reference - input is not witnessing anything it is simply - provided in the plutus script context. - --required-signer FILE Input filepath of the signing key (zero or more) - whose signature is required. - --required-signer-hash HASH - Hash of the verification key (zero or more) whose - signature is required. - --tx-in-collateral TX-IN TxId#TxIx - --tx-out-return-collateral ADDRESS VALUE - The transaction output as ADDRESS VALUE where ADDRESS - is the Bech32-encoded address followed by the value - in Lovelace. In the situation where your collateral - txin over collateralizes the transaction, you can - optionally specify a tx out of your choosing to - return the excess Lovelace. - --tx-total-collateral INTEGER - The total amount of collateral that will be collected - as fees in the event of a Plutus script failure. Must - be used in conjuction with - "--tx-out-return-collateral". - --tx-out ADDRESS VALUE The transaction output as ADDRESS VALUE where ADDRESS - is the Bech32-encoded address followed by the value - in the multi-asset syntax (including simply - Lovelace). - --tx-out-datum-hash HASH The script datum hash for this tx output, as the raw - datum hash (in hex). - --tx-out-datum-hash-cbor-file CBOR_FILE - The script datum hash for this tx output, by hashing - the script datum in the file. The file has to be in - CBOR format. - --tx-out-datum-hash-file JSON_FILE - The script datum hash for this tx output, by hashing - the script datum in the file. The file must follow - the detailed JSON schema for script data. - --tx-out-datum-hash-value JSON_VALUE - The script datum hash for this tx output, by hashing - the script datum given here. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --tx-out-datum-embed-cbor-file CBOR_FILE - The script datum to embed in the tx for this output, - in the given file. The file has to be in CBOR format. - --tx-out-datum-embed-file JSON_FILE - The script datum to embed in the tx for this output, - in the given file. The file must follow the detailed - JSON schema for script data. - --tx-out-datum-embed-value JSON_VALUE - The script datum to embed in the tx for this output, - given here. There is no schema: (almost) any JSON - value is supported, including top-level strings and - numbers. - --tx-out-inline-datum-cbor-file CBOR_FILE - The script datum to embed in the tx output as an - inline datum, in the given file. The file has to be - in CBOR format. - --tx-out-inline-datum-file JSON_FILE - The script datum to embed in the tx output as an - inline datum, in the given file. The file must follow - the detailed JSON schema for script data. - --tx-out-inline-datum-value JSON_VALUE - The script datum to embed in the tx output as an - inline datum, given here. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --tx-out-reference-script-file FILE - Reference script input file. - --change-address ADDRESS Address where ADA in excess of the tx fee will go to. - --mint VALUE Mint multi-asset value(s) with the multi-asset cli - syntax. You must specify a script witness. - --mint-script-file FILE The file containing the script to witness the minting - of assets for a particular policy Id. - --mint-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --mint-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --mint-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --simple-minting-script-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a simple reference script attached. - --policy-id HASH Policy id of minting script. - --mint-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --mint-plutus-script-v2 Specify a plutus script v2 reference script. - --mint-plutus-script-v3 Specify a plutus script v3 reference script. - --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --mint-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --mint-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --policy-id HASH Policy id of minting script. - --invalid-before SLOT Time that transaction is valid from (in slots). - --invalid-hereafter SLOT Time that transaction is valid until (in slots). - --certificate-file FILE Filepath of the certificate. This encompasses all - types of certificates (stake pool certificates, stake - key certificates etc). Optionally specify a script - witness. - --certificate-script-file FILE - The file containing the script to witness the use of - the certificate. - --certificate-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --certificate-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --certificate-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --certificate-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --certificate-plutus-script-v2 - Specify a plutus script v2 reference script. - --certificate-plutus-script-v3 - Specify a plutus script v3 reference script. - --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --certificate-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --certificate-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --withdrawal WITHDRAWAL The reward withdrawal as StakeAddress+Lovelace where - StakeAddress is the Bech32-encoded stake address - followed by the amount in Lovelace. Optionally - specify a script witness. - --withdrawal-script-file FILE - The file containing the script to witness the - withdrawal of rewards. - --withdrawal-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --withdrawal-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --withdrawal-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --withdrawal-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --withdrawal-plutus-script-v2 - Specify a plutus script v2 reference script. - --withdrawal-plutus-script-v3 - Specify a plutus script v3 reference script. - --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --withdrawal-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --json-metadata-no-schema - Use the "no schema" conversion from JSON to tx - metadata (default). - --json-metadata-detailed-schema - Use the "detailed schema" conversion from JSON to tx - metadata. - --auxiliary-script-file FILE - Filepath of auxiliary script(s) - --metadata-json-file FILE - Filepath of the metadata file, in JSON format. - --metadata-cbor-file FILE - Filepath of the metadata, in raw CBOR format. - --update-proposal-file FILE - Filepath of the update proposal. - --out-file FILE Output filepath of the JSON TxBody. - --calculate-plutus-script-cost FILE - (File () Out) filepath of the script cost - information. - -h,--help Show this help text diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_transaction.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_transaction.cli index 7d1e28c388..b5ef5529fc 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_transaction.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_transaction.cli @@ -1,6 +1,5 @@ Usage: cardano-cli shelley transaction ( build-raw - | build | sign | witness | assemble @@ -21,9 +20,6 @@ Available options: Available commands: build-raw Build a transaction (low-level, inconvenient) - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - build Build a balanced transaction (automatically calculates fees) - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m sign Sign a transaction witness Create a transaction witness diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_transaction_build.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_transaction_build.cli deleted file mode 100644 index eb60d503ad..0000000000 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_transaction_build.cli +++ /dev/null @@ -1,393 +0,0 @@ -Usage: cardano-cli shelley transaction build --socket-path SOCKET_PATH - [--cardano-mode - [--epoch-slots SLOTS]] - ( --mainnet - | --testnet-magic NATURAL - ) - [ --script-valid - | --script-invalid - ] - [--witness-override WORD] - (--tx-in TX-IN - [ --spending-tx-in-reference TX-IN - ( --spending-plutus-script-v2 - | --spending-plutus-script-v3 - ) - ( --spending-reference-tx-in-datum-cbor-file CBOR_FILE - | --spending-reference-tx-in-datum-file JSON_FILE - | --spending-reference-tx-in-datum-value JSON_VALUE - | --spending-reference-tx-in-inline-datum-present - ) - ( --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --spending-reference-tx-in-redeemer-file JSON_FILE - | --spending-reference-tx-in-redeemer-value JSON_VALUE - ) - | --simple-script-tx-in-reference TX-IN - | --tx-in-script-file FILE - [ - ( --tx-in-datum-cbor-file CBOR_FILE - | --tx-in-datum-file JSON_FILE - | --tx-in-datum-value JSON_VALUE - | --tx-in-inline-datum-present - ) - ( --tx-in-redeemer-cbor-file CBOR_FILE - | --tx-in-redeemer-file JSON_FILE - | --tx-in-redeemer-value JSON_VALUE - )] - ]) - [--read-only-tx-in-reference TX-IN] - [ --required-signer FILE - | --required-signer-hash HASH - ] - [--tx-in-collateral TX-IN] - [--tx-out-return-collateral ADDRESS VALUE] - [--tx-total-collateral INTEGER] - [--tx-out ADDRESS VALUE - [ --tx-out-datum-hash HASH - | --tx-out-datum-hash-cbor-file CBOR_FILE - | --tx-out-datum-hash-file JSON_FILE - | --tx-out-datum-hash-value JSON_VALUE - | --tx-out-datum-embed-cbor-file CBOR_FILE - | --tx-out-datum-embed-file JSON_FILE - | --tx-out-datum-embed-value JSON_VALUE - | --tx-out-inline-datum-cbor-file CBOR_FILE - | --tx-out-inline-datum-file JSON_FILE - | --tx-out-inline-datum-value JSON_VALUE - ] - [--tx-out-reference-script-file FILE]] - --change-address ADDRESS - [--mint VALUE - ( --mint-script-file FILE - [ --mint-redeemer-cbor-file CBOR_FILE - | --mint-redeemer-file JSON_FILE - | --mint-redeemer-value JSON_VALUE - ] - | --simple-minting-script-tx-in-reference TX-IN - --policy-id HASH - | --mint-tx-in-reference TX-IN - ( --mint-plutus-script-v2 - | --mint-plutus-script-v3 - ) - ( --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --mint-reference-tx-in-redeemer-file JSON_FILE - | --mint-reference-tx-in-redeemer-value JSON_VALUE - ) - --policy-id HASH - )] - [--invalid-before SLOT] - [--invalid-hereafter SLOT] - [--certificate-file FILE - [ --certificate-script-file FILE - [ --certificate-redeemer-cbor-file CBOR_FILE - | --certificate-redeemer-file JSON_FILE - | --certificate-redeemer-value JSON_VALUE - ] - | --certificate-tx-in-reference TX-IN - ( --certificate-plutus-script-v2 - | --certificate-plutus-script-v3 - ) - ( --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --certificate-reference-tx-in-redeemer-file JSON_FILE - | --certificate-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [--withdrawal WITHDRAWAL - [ --withdrawal-script-file FILE - [ --withdrawal-redeemer-cbor-file CBOR_FILE - | --withdrawal-redeemer-file JSON_FILE - | --withdrawal-redeemer-value JSON_VALUE - ] - | --withdrawal-tx-in-reference TX-IN - ( --withdrawal-plutus-script-v2 - | --withdrawal-plutus-script-v3 - ) - ( --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - | --withdrawal-reference-tx-in-redeemer-file JSON_FILE - | --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - ) - ]] - [ --json-metadata-no-schema - | --json-metadata-detailed-schema - ] - [--auxiliary-script-file FILE] - [ --metadata-json-file FILE - | --metadata-cbor-file FILE - ] - [--update-proposal-file FILE] - ( --out-file FILE - | --calculate-plutus-script-cost FILE - ) - - Build a balanced transaction (automatically calculates fees) - - Please note the order[93;22;23;24m of some cmd options is crucial. If used incorrectly may produce undesired tx body. See nested [] notation above for details.[0;22;23;24m - -Available options: - --socket-path SOCKET_PATH - Path to the node socket. This overrides the - CARDANO_NODE_SOCKET_PATH environment variable. The - argument is optional if CARDANO_NODE_SOCKET_PATH is - defined and mandatory otherwise. - --cardano-mode For talking to a node running in full Cardano mode - (default). - --epoch-slots SLOTS The number of slots per epoch for the Byron era. - (default: 21600) - --mainnet Use the mainnet magic id. This overrides the - CARDANO_NODE_NETWORK_ID environment variable - --testnet-magic NATURAL Specify a testnet magic id. This overrides the - CARDANO_NODE_NETWORK_ID environment variable - --script-valid Assertion that the script is valid. (default) - --script-invalid Assertion that the script is invalid. If a - transaction is submitted with such a script, the - script will fail and the collateral will be taken. - --witness-override WORD Specify and override the number of witnesses the - transaction requires. - --tx-in TX-IN TxId#TxIx - --spending-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --spending-plutus-script-v2 - Specify a plutus script v2 reference script. - --spending-plutus-script-v3 - Specify a plutus script v3 reference script. - --spending-reference-tx-in-datum-cbor-file CBOR_FILE - The script datum file. The file has to be in CBOR - format. - --spending-reference-tx-in-datum-file JSON_FILE - The script datum file. The file must follow the - detailed JSON schema for script data. - --spending-reference-tx-in-datum-value JSON_VALUE - The script datum. There is no schema: (almost) any - JSON value is supported, including top-level strings - and numbers. - --spending-reference-tx-in-inline-datum-present - Inline datum present at transaction input. - --spending-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --spending-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --spending-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --simple-script-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a simple reference script attached. - --tx-in-script-file FILE The file containing the script to witness the - spending of the transaction input. - --tx-in-datum-cbor-file CBOR_FILE - The script datum file. The file has to be in CBOR - format. - --tx-in-datum-file JSON_FILE - The script datum file. The file must follow the - detailed JSON schema for script data. - --tx-in-datum-value JSON_VALUE - The script datum. There is no schema: (almost) any - JSON value is supported, including top-level strings - and numbers. - --tx-in-inline-datum-present - Inline datum present at transaction input. - --tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --read-only-tx-in-reference TX-IN - Specify a read only reference input. This reference - input is not witnessing anything it is simply - provided in the plutus script context. - --required-signer FILE Input filepath of the signing key (zero or more) - whose signature is required. - --required-signer-hash HASH - Hash of the verification key (zero or more) whose - signature is required. - --tx-in-collateral TX-IN TxId#TxIx - --tx-out-return-collateral ADDRESS VALUE - The transaction output as ADDRESS VALUE where ADDRESS - is the Bech32-encoded address followed by the value - in Lovelace. In the situation where your collateral - txin over collateralizes the transaction, you can - optionally specify a tx out of your choosing to - return the excess Lovelace. - --tx-total-collateral INTEGER - The total amount of collateral that will be collected - as fees in the event of a Plutus script failure. Must - be used in conjuction with - "--tx-out-return-collateral". - --tx-out ADDRESS VALUE The transaction output as ADDRESS VALUE where ADDRESS - is the Bech32-encoded address followed by the value - in the multi-asset syntax (including simply - Lovelace). - --tx-out-datum-hash HASH The script datum hash for this tx output, as the raw - datum hash (in hex). - --tx-out-datum-hash-cbor-file CBOR_FILE - The script datum hash for this tx output, by hashing - the script datum in the file. The file has to be in - CBOR format. - --tx-out-datum-hash-file JSON_FILE - The script datum hash for this tx output, by hashing - the script datum in the file. The file must follow - the detailed JSON schema for script data. - --tx-out-datum-hash-value JSON_VALUE - The script datum hash for this tx output, by hashing - the script datum given here. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --tx-out-datum-embed-cbor-file CBOR_FILE - The script datum to embed in the tx for this output, - in the given file. The file has to be in CBOR format. - --tx-out-datum-embed-file JSON_FILE - The script datum to embed in the tx for this output, - in the given file. The file must follow the detailed - JSON schema for script data. - --tx-out-datum-embed-value JSON_VALUE - The script datum to embed in the tx for this output, - given here. There is no schema: (almost) any JSON - value is supported, including top-level strings and - numbers. - --tx-out-inline-datum-cbor-file CBOR_FILE - The script datum to embed in the tx output as an - inline datum, in the given file. The file has to be - in CBOR format. - --tx-out-inline-datum-file JSON_FILE - The script datum to embed in the tx output as an - inline datum, in the given file. The file must follow - the detailed JSON schema for script data. - --tx-out-inline-datum-value JSON_VALUE - The script datum to embed in the tx output as an - inline datum, given here. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --tx-out-reference-script-file FILE - Reference script input file. - --change-address ADDRESS Address where ADA in excess of the tx fee will go to. - --mint VALUE Mint multi-asset value(s) with the multi-asset cli - syntax. You must specify a script witness. - --mint-script-file FILE The file containing the script to witness the minting - of assets for a particular policy Id. - --mint-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --mint-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --mint-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --simple-minting-script-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a simple reference script attached. - --policy-id HASH Policy id of minting script. - --mint-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --mint-plutus-script-v2 Specify a plutus script v2 reference script. - --mint-plutus-script-v3 Specify a plutus script v3 reference script. - --mint-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --mint-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --mint-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --policy-id HASH Policy id of minting script. - --invalid-before SLOT Time that transaction is valid from (in slots). - --invalid-hereafter SLOT Time that transaction is valid until (in slots). - --certificate-file FILE Filepath of the certificate. This encompasses all - types of certificates (stake pool certificates, stake - key certificates etc). Optionally specify a script - witness. - --certificate-script-file FILE - The file containing the script to witness the use of - the certificate. - --certificate-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --certificate-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --certificate-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --certificate-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --certificate-plutus-script-v2 - Specify a plutus script v2 reference script. - --certificate-plutus-script-v3 - Specify a plutus script v3 reference script. - --certificate-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --certificate-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --certificate-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --withdrawal WITHDRAWAL The reward withdrawal as StakeAddress+Lovelace where - StakeAddress is the Bech32-encoded stake address - followed by the amount in Lovelace. Optionally - specify a script witness. - --withdrawal-script-file FILE - The file containing the script to witness the - withdrawal of rewards. - --withdrawal-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --withdrawal-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --withdrawal-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --withdrawal-tx-in-reference TX-IN - TxId#TxIx - Specify a reference input. The reference - input must have a plutus reference script attached. - --withdrawal-plutus-script-v2 - Specify a plutus script v2 reference script. - --withdrawal-plutus-script-v3 - Specify a plutus script v3 reference script. - --withdrawal-reference-tx-in-redeemer-cbor-file CBOR_FILE - The script redeemer file. The file has to be in CBOR - format. - --withdrawal-reference-tx-in-redeemer-file JSON_FILE - The script redeemer file. The file must follow the - detailed JSON schema for script data. - --withdrawal-reference-tx-in-redeemer-value JSON_VALUE - The script redeemer value. There is no schema: - (almost) any JSON value is supported, including - top-level strings and numbers. - --json-metadata-no-schema - Use the "no schema" conversion from JSON to tx - metadata (default). - --json-metadata-detailed-schema - Use the "detailed schema" conversion from JSON to tx - metadata. - --auxiliary-script-file FILE - Filepath of auxiliary script(s) - --metadata-json-file FILE - Filepath of the metadata file, in JSON format. - --metadata-cbor-file FILE - Filepath of the metadata, in raw CBOR format. - --update-proposal-file FILE - Filepath of the update proposal. - --out-file FILE Output filepath of the JSON TxBody. - --calculate-plutus-script-cost FILE - (File () Out) filepath of the script cost - information. - -h,--help Show this help text diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/transaction_build.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/transaction_build.cli index 0bb2ca8757..2a431afe52 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/transaction_build.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/transaction_build.cli @@ -1,10 +1,5 @@ Usage: cardano-cli transaction build --socket-path SOCKET_PATH - [ --shelley-era - | --allegra-era - | --mary-era - | --alonzo-era - | --babbage-era - ] + [--babbage-era | --conway-era] [--cardano-mode [--epoch-slots SLOTS]] (--mainnet | --testnet-magic NATURAL) [--script-valid | --script-invalid] @@ -156,16 +151,8 @@ Available options: CARDANO_NODE_SOCKET_PATH environment variable. The argument is optional if CARDANO_NODE_SOCKET_PATH is defined and mandatory otherwise. - --shelley-era Specify the Shelley era - DEPRECATED - will be - removed in the future - --allegra-era Specify the Allegra era - DEPRECATED - will be - removed in the future - --mary-era Specify the Mary era - DEPRECATED - will be removed - in the future - --alonzo-era Specify the Alonzo era - DEPRECATED - will be removed - in the future - --babbage-era Specify the Babbage era (default) - DEPRECATED - will - be removed in the future + --babbage-era Specify the Babbage era (default) + --conway-era Specify the Conway era --cardano-mode For talking to a node running in full Cardano mode (default). --epoch-slots SLOTS The number of slots per epoch for the Byron era.