The gift that keeps on giving 🥰
BirthdayBucks 🎂 implements an ERC-20 token that always has as many tokens as a your friend has years
Deploy the contract with...
- A name (ex: SpencePence)
- A symbol (ex: SPNC)
- Your birthday bud's wallet and birthday
...and all new supply will be minted to them 🎁
The token uses rebasing, so no transactions are required to collect new supply
$ git clone https://github.com/lukevs/birthday-bucks; cd birthday-bucks
$ yarn install
Create a .env
file with the following values:
- MNEMONIC - secret words for your own wallet - you'll use this wallet to deploy the contract (find on MetaMask)
- INFURA_API_KEY - if you don't have an account register here, then create a project for the token to get a key
- BIRTHDAY_TOKEN_NAME - The name of the token (ex: SpencePence, LukeLoot, DannyDoubloons)
- BIRTHDAY_TOKEN_SYMBOL - The symbol of the token (ex: SPNC, LOOT, DNYS)
- BIRTHDAY_BUD_ADDRESS - The birthday bud's wallet address - all current and future supply will be given to them
- BIRTHDAY_UTC_SECONDS - The birthday bud's moment of birth in UTC seconds (UTC second calculator)
Example .env
MNEMONIC=birthday birthday birthday birthday birthday birthday birthday birthday birthday birthday birthday birthday
INFURA_API_KEY=abc123doremi
BIRTHDAY_TOKEN_NAME=SpencePence
BIRTHDAY_TOKEN_SYMBOL=SPNC
BIRTHDAY_BUD_ADDRESS=0x1111111111111111111111111111111111111111
BIRTHDAY_UTC_SECONDS=600000000
To ensure all looks good, deploy to a testnet (we're using Ropsten)
If your account has no ETH on Ropsten, request it here
Deploy with:
yarn deploy:network ropsten
Review the deployed contract by searching the contract address on the Ropsten etherscan
Ensure your wallet (the one tied to MNEMONIC) has enough money to deploy the contract on mainnet
(~0.016 ETH at the time of writing)
Deploy with:
yarn deploy:network mainnet
Again check that all went well on the main etherscan
Celebrate with some cake! 🍰
PR to add your own 🎉
Would love to see some PRs!
See the README for paulrberg/solidity-template to see all the tools available in this repo.