Crypto DeFi
A comprehensive crypto toolkit for tracking DeFi positions, managing portfolios, monitoring prices, watching whale activity, and analyzing market data. Crypto DeFi provides 16+ commands for recording and reviewing crypto-related observations with timestamped logs and multi-format data export.
Commands
| Command | Description |
|---|
| INLINECODE0 | Record a tracking entry (token, protocol, position) — run without args to view recent entries |
| INLINECODE1 |
Log a portfolio update or snapshot — run without args to view recent portfolio entries |
|
crypto-defi alert <input> | Record a price or event alert — run without args to view recent alerts |
|
crypto-defi price <input> | Log a price observation — run without args to view recent price entries |
|
crypto-defi compare <input> | Record a protocol or token comparison — run without args to view recent comparisons |
|
crypto-defi history <input> | Log a historical note — run without args to view recent history entries |
|
crypto-defi gas <input> | Record gas fee data — run without args to view recent gas entries |
|
crypto-defi whale-watch <input> | Log whale activity observations — run without args to view recent whale-watch entries |
|
crypto-defi report <input> | Record a report entry — run without args to view recent reports |
|
crypto-defi watchlist <input> | Add to or view the watchlist — run without args to view recent watchlist entries |
|
crypto-defi analyze <input> | Log an analysis note — run without args to view recent analysis entries |
|
crypto-defi export <input> | Record an export event — run without args to view recent export entries |
|
crypto-defi stats | Display summary statistics across all log categories |
|
crypto-defi search <term> | Search across all log files for a keyword |
|
crypto-defi recent | Show the 20 most recent activity entries from the history log |
|
crypto-defi status | Health check — shows version, data directory, entry count, disk usage |
|
crypto-defi help | Display available commands and usage information |
|
crypto-defi version | Print current version (v2.0.0) |
Each data command (track, portfolio, alert, etc.) works in two modes:
- - With arguments: Records the input with a timestamp into its dedicated log file
- Without arguments: Displays the 20 most recent entries from that category
Data Storage
All data is stored locally in plain-text log files:
- - Location: INLINECODE18
- Format: Each entry is saved as
YYYY-MM-DD HH:MM|<value> in per-category .log files - History: All operations are additionally logged to
history.log with timestamps - Stats: The
stats command aggregates entry counts and disk usage across all categories - No cloud sync — everything stays on your machine, no API keys needed
Requirements
- - Bash 4.0+ (uses
set -euo pipefail) - Standard Unix utilities:
date, wc, du, head, tail, grep, basename, INLINECODE31 - No external dependencies, no API keys, no network access required
- Works on Linux and macOS
When to Use
- 1. DeFi position tracking — Record yield farming positions, staking entries, and liquidity pool allocations with timestamps for historical review
- Portfolio management — Log portfolio snapshots, token balances, and allocation changes to maintain a running record of your holdings
- Whale activity monitoring — Use
whale-watch to record large transaction observations and spot market-moving activity patterns - Gas fee tracking — Log gas fee observations over time to identify optimal transaction windows and track network congestion trends
- Multi-protocol comparison — Use
compare and analyze to record side-by-side protocol evaluations and store your analysis notes
Examples
CODEBLOCK0
Configuration
Set DATA_DIR by modifying the script or symlinking ~/.local/share/crypto-defi/ to your preferred location.
Powered by BytesAgain | bytesagain.com | hello@bytesagain.com
技能名称: DeFi计算器
加密DeFi
一个全面的加密工具包,用于追踪DeFi头寸、管理投资组合、监控价格、观察鲸鱼活动以及分析市场数据。加密DeFi提供16+条命令,用于记录和审查与加密相关的观察结果,并带有时间戳日志和多格式数据导出。
命令
| 命令 | 描述 |
|---|
| crypto-defi track <输入> | 记录追踪条目(代币、协议、头寸)—— 无参数运行可查看最近条目 |
| crypto-defi portfolio <输入> |
记录投资组合更新或快照 —— 无参数运行可查看最近投资组合条目 |
| crypto-defi alert <输入> | 记录价格或事件警报 —— 无参数运行可查看最近警报 |
| crypto-defi price <输入> | 记录价格观察 —— 无参数运行可查看最近价格条目 |
| crypto-defi compare <输入> | 记录协议或代币比较 —— 无参数运行可查看最近比较 |
| crypto-defi history <输入> | 记录历史笔记 —— 无参数运行可查看最近历史条目 |
| crypto-defi gas <输入> | 记录Gas费用数据 —— 无参数运行可查看最近Gas条目 |
| crypto-defi whale-watch <输入> | 记录鲸鱼活动观察 —— 无参数运行可查看最近鲸鱼观察条目 |
| crypto-defi report <输入> | 记录报告条目 —— 无参数运行可查看最近报告 |
| crypto-defi watchlist <输入> | 添加到或查看观察列表 —— 无参数运行可查看最近观察列表条目 |
| crypto-defi analyze <输入> | 记录分析笔记 —— 无参数运行可查看最近分析条目 |
| crypto-defi export <输入> | 记录导出事件 —— 无参数运行可查看最近导出条目 |
| crypto-defi stats | 显示所有日志类别的汇总统计 |
| crypto-defi search <关键词> | 在所有日志文件中搜索关键词 |
| crypto-defi recent | 显示历史日志中最近20条活动条目 |
| crypto-defi status | 健康检查 —— 显示版本、数据目录、条目数量、磁盘使用情况 |
| crypto-defi help | 显示可用命令和使用信息 |
| crypto-defi version | 打印当前版本(v2.0.0) |
每个数据命令(track、portfolio、alert等)有两种工作模式:
- - 带参数:将输入连同时间戳记录到其专用日志文件中
- 无参数:显示该类别中最近20条条目
数据存储
所有数据本地存储在纯文本日志文件中:
- - 位置:~/.local/share/crypto-defi/
- 格式:每个条目按YYYY-MM-DD HH:MM|<值>格式保存到按类别划分的.log文件中
- 历史记录:所有操作还会额外记录到history.log中,并带有时间戳
- 统计:stats命令汇总所有类别的条目数量和磁盘使用情况
- 无云同步 —— 所有数据保留在您的机器上,无需API密钥
要求
- - Bash 4.0+(使用set -euo pipefail)
- 标准Unix工具:date、wc、du、head、tail、grep、basename、cat
- 无外部依赖、无API密钥、无需网络访问
- 适用于Linux和macOS
使用场景
- 1. DeFi头寸追踪 —— 记录收益农耕头寸、质押条目和流动性池分配,并带有时间戳,便于历史回顾
- 投资组合管理 —— 记录投资组合快照、代币余额和配置变化,以维护持仓的持续记录
- 鲸鱼活动监控 —— 使用whale-watch记录大额交易观察结果,发现影响市场的活动模式
- Gas费用追踪 —— 随时间记录Gas费用观察结果,以识别最佳交易窗口并追踪网络拥堵趋势
- 多协议比较 —— 使用compare和analyze记录并排协议评估,并存储您的分析笔记
示例
bash
追踪一个新的DeFi头寸
crypto-defi track Uniswap V3 ETH/USDC 0.3%池 — 存入5 ETH
记录当前投资组合状态
crypto-defi portfolio BTC: 0.5, ETH: 10, SOL: 200 — 总计约$45k
记录价格警报触发
crypto-defi alert ETH突破$4000阻力位
记录Gas费用观察
crypto-defi gas 以太坊主网基础费用25 gwei — 适合进行兑换
记录鲸鱼活动
crypto-defi whale-watch 0xdead...向币安充值地址转移了10,000 ETH
查看所有类别的汇总统计
crypto-defi stats
搜索所有提及特定协议的条目
crypto-defi search Uniswap
快速健康检查
crypto-defi status
配置
通过修改脚本或将~/.local/share/crypto-defi/符号链接到您偏好的位置来设置DATA_DIR。
由BytesAgain提供 | bytesagain.com | hello@bytesagain.com