git-subtree-dir: server git-subtree-mainline:c4e617ada7git-subtree-split:e64421295f
12 lines
325 B
Bash
12 lines
325 B
Bash
#!/bin/bash
|
|
# 路由快照:输出 /api.json 的全部路径(排序去重)
|
|
# 用法:bash scripts/routes.sh > /tmp/routes-before.txt
|
|
set -e
|
|
BASE="${BASE:-http://localhost:3007}"
|
|
curl -s "$BASE/api.json" | python3 -c "
|
|
import json, sys
|
|
d = json.load(sys.stdin)
|
|
for p in sorted(d.get('paths', {}).keys()):
|
|
print(p)
|
|
"
|