Skip to content

Commit

Permalink
Update voting.md
Browse files Browse the repository at this point in the history
conway era and --mainnet were missing from some of the cardano-cli commands.
  • Loading branch information
shawnim authored Jan 19, 2025
1 parent 00bd7b0 commit d2efc19
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions docs/get-started/cardano-cli/governance/voting.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Assume we need to submit a vote on the governance action with ID `df58f714c0765f
1. Obtain the URL and hash of the new constitution proposal from the governance state:

```shell
cardano-cli conway query gov-state | \
cardano-cli conway query gov-state --mainnet | \
jq -r --arg govActionId "df58f714c0765f3489afb6909384a16c31d600695be7e86ff9c59cf2e8a48c79" '.proposals | to_entries[] | select(.value.actionId.txId | contains($govActionId)) | .value'
```
```json
Expand Down Expand Up @@ -95,6 +95,7 @@ cardano-cli conway governance vote create \
--governance-action-tx-id "df58f714c0765f3489afb6909384a16c31d600695be7e86ff9c59cf2e8a48c79" \
--governance-action-index "0" \
--drep-verification-key-file drep.vkey \
--mainnet \
--out-file df58f714c0765f3489afb6909384a16c31d600695be7e86ff9c59cf2e8a48c79-constitution.vote
```

Expand All @@ -106,6 +107,7 @@ cardano-cli conway governance vote create \
--governance-action-tx-id "df58f714c0765f3489afb6909384a16c31d600695be7e86ff9c59cf2e8a48c79" \
--governance-action-index "0" \
--cc-hot-verification-key-file cc-hot.vkey \
--mainnet \
--out-file df58f714c0765f3489afb6909384a16c31d600695be7e86ff9c59cf2e8a48c79-constitution.vote
```
Voting with SPO keys:
Expand All @@ -116,6 +118,7 @@ cardano-cli conway governance vote create \
--governance-action-tx-id "df58f714c0765f3489afb6909384a16c31d600695be7e86ff9c59cf2e8a48c79" \
--governance-action-index "0" \
--cold-verification-key-file cold.vkey \
--mainnet \
--out-file df58f714c0765f3489afb6909384a16c31d600695be7e86ff9c59cf2e8a48c79-constitution.vote
```

Expand All @@ -129,13 +132,15 @@ cardano-cli conway transaction build \
--change-address $(< payment.addr) \
--vote-file df58f714c0765f3489afb6909384a16c31d600695be7e86ff9c59cf2e8a48c79-constitution.vote \
--witness-override 2 \
--mainnet \
--out-file vote-tx.raw
```
Sign it with the DRep key:
```shell
cardano-cli transaction sign --tx-body-file vote-tx.raw \
cardano-cli conway transaction sign --tx-body-file vote-tx.raw \
--signing-key-file drep.skey \
--signing-key-file payment.skey \
--mainnet \
--out-file vote-tx.signed
```
OR sign it with the CC hot key:
Expand All @@ -147,12 +152,13 @@ cardano-cli transaction sign --tx-body-file vote-tx.raw \
```
OR sign it with the SPO cold key:
```shell
cardano-cli transaction sign --tx-body-file vote-tx.raw \
cardano-cli conway transaction sign --tx-body-file vote-tx.raw \
--signing-key-file cold.skey \
--signing-key-file payment.skey \
--mainnet \
--out-file vote-tx.signed
```
Submit the transaction:
```shell
cardano-cli transaction submit --tx-file vote-tx.signed
```
cardano-cli conway transaction submit --mainnet --tx-file vote-tx.signed
```

0 comments on commit d2efc19

Please sign in to comment.