Files
qihuo/scripts/deploy_responsive.py
T
dekun c5262a0a54 Add responsive mobile layout, records cards, and tablet settings fold fix.
Mobile gets compact trade/records UI with detail modals; static assets are cache-busted and settings cards fold correctly on tablet grid layout.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-29 16:42:38 +08:00

35 lines
1.0 KiB
Python

"""Deploy responsive / orientation layout fixes."""
import paramiko
import sys
from pathlib import Path
sys.stdout.reconfigure(encoding="utf-8", errors="replace")
root = Path(__file__).resolve().parents[1]
files = [
"app.py",
"static/css/trade.css",
"static/css/mobile.css",
"static/css/responsive.css",
"static/css/records.css",
"static/js/orientation.js",
"static/js/nav.js",
"static/js/records.js",
"static/js/settings.js",
"templates/base.html",
"templates/trade.html",
"templates/strategy.html",
"templates/records.html",
"templates/settings.html",
]
c = paramiko.SSHClient()
c.set_missing_host_key_policy(paramiko.AutoAddPolicy())
c.connect("192.168.8.21", username="root", password="woaini88", timeout=15)
sftp = c.open_sftp()
for rel in files:
sftp.put(str(root / rel), f"/opt/qihuo/{rel.replace(chr(92), '/')}")
print("uploaded", rel)
sftp.close()
_, o, _ = c.exec_command("cd /opt/qihuo && pm2 restart qihuo")
print(o.read().decode("utf-8", errors="replace"))
c.close()