grant-block-calc

command module
v0.0.0-...-c4aa525 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 14, 2023 License: MIT Imports: 6 Imported by: 0

README

Grant Block Calculator

An utility tool to calculate grant pool distributions to committees.

  1. Fill in accounts and shares in main.go. Shares are in bps (1% = 100), total shares 100% = 10000.
// accounts
const GRANT_POOL = "acc://accumulate.acme/grant-block"
const BUSINESS_COMMITTEE = "acc://accumulate.acme/business/grants"
const GOVERNANCE_COMMITTEE = "acc://accumulate.acme/governance/grants"
const ECOSYSTEM_COMMITTEE = "acc://accumulate.acme/ecosystem/grants"
const CORE_DEV_COMMITTEE = "acc://accumulate.acme/core-dev/grants"

// shares (in bps)
const BUSINESS_SHARE = 2660
const GOVERNANCE_SHARE = 2020
const ECOSYSTEM_SHARE = 2130
const CORE_DEV_SHARE = 3190
  1. Run go run main.go to calculate distribution and generate Accumulate CLI output.
go run main.go
Calculating grant pool distribution...
Getting account balance: acc://accumulate.acme/grant-block
Balance: 1242083.13194200 ACME
26% => acc://accumulate.acme/business/grants : 330394.11309657 ACME
20% => acc://accumulate.acme/governance/grants : 250900.79265228 ACME
21% => acc://accumulate.acme/ecosystem/grants : 264563.70710364 ACME
31% => acc://accumulate.acme/core-dev/grants : 396224.51908949 ACME
Generating CLI params...
{ type: sendTokens, to: [{"url":"acc://accumulate.acme/business/grants","amount":"33039411309657"},{"url":"acc://accumulate.acme/governance/grants","amount":"25090079265228"},{"url":"acc://accumulate.acme/ecosystem/grants","amount":"26456370710364"},{"url":"acc://accumulate.acme/core-dev/grants","amount":"39622451908949"}] }

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL