diff --git a/cardano-cli/src/Cardano/CLI/Shelley/Commands.hs b/cardano-cli/src/Cardano/CLI/Shelley/Commands.hs index bc681b1fdd3..553a9283de8 100644 --- a/cardano-cli/src/Cardano/CLI/Shelley/Commands.hs +++ b/cardano-cli/src/Cardano/CLI/Shelley/Commands.hs @@ -414,13 +414,12 @@ data GovernanceCmd Text -- Prompt [Text] -- Choices (Maybe Word) -- Nonce - (File () Out) + (File GovernancePoll Out) | GovernanceAnswerPoll - (File () In) -- Poll file - (SigningKeyFile In) + (File GovernancePoll In) -- Poll file (Maybe Word) -- Answer index | GovernanceVerifyPoll - (File () In) -- Poll file + (File GovernancePoll In) -- Poll file (File (Tx ()) In) -- Tx file deriving Show diff --git a/cardano-cli/src/Cardano/CLI/Shelley/Parsers.hs b/cardano-cli/src/Cardano/CLI/Shelley/Parsers.hs index bdd3cab3bd5..66320956482 100644 --- a/cardano-cli/src/Cardano/CLI/Shelley/Parsers.hs +++ b/cardano-cli/src/Cardano/CLI/Shelley/Parsers.hs @@ -1226,7 +1226,7 @@ pPollAnswerIndex = <> Opt.help "The index of the chosen answer in the poll. Optional. Asked interactively if omitted." ) -pPollFile :: Parser (File () In) +pPollFile :: Parser (File GovernancePoll In) pPollFile = Opt.strOption ( Opt.long "poll-file" diff --git a/cardano-cli/src/Cardano/CLI/Shelley/Run/Governance.hs b/cardano-cli/src/Cardano/CLI/Shelley/Run/Governance.hs index 0a2572d9895..5b4459aaccc 100644 --- a/cardano-cli/src/Cardano/CLI/Shelley/Run/Governance.hs +++ b/cardano-cli/src/Cardano/CLI/Shelley/Run/Governance.hs @@ -224,7 +224,7 @@ runGovernanceCreatePoll :: Text -> [Text] -> Maybe Word - -> File () Out + -> File GovernancePoll Out -> ExceptT ShelleyGovernanceCmdError IO () runGovernanceCreatePoll govPollQuestion govPollAnswers govPollNonce out = do let poll = GovernancePoll{ govPollQuestion, govPollAnswers, govPollNonce } @@ -255,7 +255,7 @@ runGovernanceCreatePoll govPollQuestion govPollAnswers govPollNonce out = do ] runGovernanceAnswerPoll - :: File () In + :: File GovernancePoll In -> Maybe Word -- ^ Answer index -> ExceptT ShelleyGovernanceCmdError IO () @@ -321,7 +321,7 @@ runGovernanceAnswerPoll pollFile maybeChoice = do left ShelleyGovernanceCmdPollInvalidChoice runGovernanceVerifyPoll - :: File () In + :: File GovernancePoll In -> File (Tx ()) In -> ExceptT ShelleyGovernanceCmdError IO () runGovernanceVerifyPoll pollFile txFile = do