This repository contains a script for fetching and displaying Ethereum token and NFT balances. The script is designed to be run with bun
, a fast all-in-one JavaScript runtime.
- bun installed on your system.
- An Ethereum RPC URL, which can be obtained from services like Infura or Alchemy.
- Clone the repository:
git clone https://github.com/felinaprotocol/portfolio-tracker.git
- Navigate to the project directory:
cd portfolio-tracker && cp .env.example .env
The script can be run with either an Ethereum address or an ENS name. To run the script, use the following command:
bun balance <ENS_NAME_OR_ADDRESS>
For example:
bun balance vitalik.eth
or
bun balance 0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045
The script will resolve the ENS name to an Ethereum address if necessary, and then it will fetch and display the balance information.
Contributions to this project are welcome. Please ensure that your code adheres to the existing style and that all tests pass.
This project is licensed under the MIT License - see the LICENSE file for details.