A command-line application for managing account ledgers with support for multiple account types, GitHub Gist integration, and comprehensive transaction processing.
- Account ledger management
- Gist-based data storage and synchronization
- Multiple account type support (wallet, bank, expense, income, assets)
- Transaction processing and tracking
- Account relationship management
- Bajaj rewards integration (coins and cashback)
- Sheet-based account reporting
- Dart SDK
- Java (for certain operations)
- GitHub account (for Gist integration)
This application requires environment variables to be configured. Follow these steps:
-
Copy the example environment file:
cp .env_example .env
-
Edit
.envwith your specific values:User Credentials:
USER_NAME: Your account usernamePASSWORD: Your account passwordUSER_ID: Your unique user ID (positive integer)
Account Configuration:
WALLET_ACCOUNT_ID: Your wallet account ID (positive integer)BANK_ACCOUNT_ID: Your bank account ID (positive integer)BANK_ACCOUNT_NAME: Name of your bank accountFREQUENT_1/2/3_ACCOUNT_ID: IDs for frequently used accounts (positive integers)FREQUENT_1/2/3_ACCOUNT_NAME: Names for frequently used accounts
Account ID Lists:
Configure comma-separated account IDs (positive integers) for various categories:
OPEN_BALANCE_ACCOUNT_IDS: Open balance accountsMISC_INCOME_ACCOUNT_IDS: Miscellaneous income accountsINVESTMENT_RETURNS_ACCOUNT_IDS: Investment return accountsFAMILY_ACCOUNT_IDS: Family-related accountsEXPENSE_ACCOUNT_IDS: Expense accountsEXPENSE_ACCOUNT_IDS_FOR_SHEET: Expense accounts for sheet operationsINCOME_ACCOUNT_IDS_FOR_SHEET: Income accounts for sheet operationsEXPENSE_INCOME_IGNORE_ACCOUNT_IDS_FOR_SHEET: Accounts to ignore in expense/income sheetsDEBIT_OR_CREDIT_ACCOUNT_IDS_FOR_SHEET: Debit/credit accounts for sheetsEXPENSE_INCOME_DEBIT_CREDIT_IGNORE_ACCOUNT_IDS_FOR_SHEET: Combined ignore listASSET_ACCOUNT_IDS_FOR_SHEET: Asset accounts for sheet operationsEXPENSE_INCOME_DEBIT_CREDIT_ASSET_IGNORE_ACCOUNT_IDS_FOR_SHEET: Comprehensive ignore list
Bajaj Integration:
BAJAJ_COINS_INCOME_ACCOUNT_ID: Bajaj coins income account IDBAJAJ_COINS_WALLET_ACCOUNT_ID: Bajaj coins wallet account IDBAJAJ_COINS_CONVERSION_RATE: Conversion rate for Bajaj coins (default: 5)BAJAJ_CASHBACK_INCOME_ACCOUNT_ID: Bajaj cashback income account IDBAJAJ_CASHBACK_ACCOUNT_ID: Bajaj cashback account ID
GitHub Integration:
GITHUB_TOKEN: Your GitHub personal access token (requires Gist permissions)GIST_ID: Your GitHub Gist ID for data storageGIST_FILE_LINE_SEPARATOR: Line separator for Gist files (default: '\n')
Server Configuration:
SERVER_ADDRESS: Your API server URLHTTP_API_FOLDER: API folder pathFILE_EXTENSION: API file extension
Development:
IS_DEVELOPMENT_MODE: Set totruefor development,falsefor production
Java Configuration:
JAVA_HOME_WINDOWS: Java installation path for WindowsJAVA_HOME_MAC: Java installation path for macOSJAVA_HOME_LINUX: Java installation path for Linux
Note: Forward slashes (/) work on all platforms including Windows
-
Clone the repository
-
Install dependencies:
dart pub get
-
Configure your
.envfile as described above
Run the CLI application:
dart run bin/account_ledger_cli_dart.dartaccount_ledger_cli_dart/
├── bin/
│ └── account_ledger_cli_dart.dart # Main entrypoint
├── lib/
│ ├── account_ledger_cli_command_runner.dart
│ ├── get_accounts_command.dart
│ ├── process_gist_v2_account_ledger_command.dart
│ ├── process_gist_v3_account_ledger_command.dart
│ ├── process_gist_v4_account_ledger_command.dart
│ ├── verify_gist_account_ledger_command.dart
│ └── verify_gist_v2_account_ledger_command.dart
└── account_ledger_library_dart/ # Core library
├── lib/
│ ├── models/ # Data models
│ ├── common_utils/ # Utility functions
│ └── utils/ # Additional utilities
└── api/ # HTTP API examples
- All account IDs should be positive unique integers
- Regularly rotate your
GITHUB_TOKEN - Use environment-specific configuration for different deployment environments
- Never commit sensitive credentials to version control
For development purposes:
- Set
IS_DEVELOPMENT_MODE=truein your.envfile - Use the development configuration as needed