Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: generate genesis UTxOs from config files #59

Merged
merged 9 commits into from
Oct 4, 2023
Merged

Conversation

scarmuega
Copy link
Member

@scarmuega scarmuega commented Feb 25, 2022

This PR provides a way to load Byron json config files and generate the corresponding genesis UTxOs from the data.

use pallas::ledger::configs::byron;

let config = byron::from_file(&path).unwrap();
let utxos = byron::genesis_utxos(&config);

for (tx_hash, address, amount) in utxos {
  format!("{tx_hash} - {address} - {amount}");
}

@scarmuega scarmuega marked this pull request as ready for review October 4, 2023 01:09
@scarmuega scarmuega merged commit a8df6dc into main Oct 4, 2023
3 checks passed
@scarmuega scarmuega deleted the feat/byron-genesis branch October 4, 2023 09:46
@scarmuega scarmuega mentioned this pull request Oct 4, 2023
4 tasks
@scarmuega scarmuega changed the title feat: Genesis config primitives feat: generate genesis UTxOs from config files Oct 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: generate genesis UTxOs from config files
3 participants