Files
biibaye/fleetbase-source/patch-index-html.py
odaybari 05818099e6 Add fleetbase-source: deploy script, patch scripts, AGENTS.md with session notes
- deploy-biibaye.sh: VPS deploy script
- patch-index-html.js: post-build HTML patching (title, favicon, meta)
- patch-css-colors.js: post-build CSS color replacement (blue -> orange)
- patch-index-html.py: Python alternative for host-side HTML patching
- console-package.json: snapshot with @biibaye/branding link dependency
- AGENTS.md: full session docs for 2026-05-24 and 2026-05-25
2026-05-25 16:43:02 +03:00

21 lines
870 B
Python

import re
path = '/opt/fleetbase/console/app/index.html'
with open(path, 'r') as f:
content = f.read()
replacements = [
('<title>Fleetbase Console</title>', '<title>Biibaye - Delivery System</title>'),
('content="#da532c"', 'content="#FF4500"'),
('content="#ffffff"', 'content="#FF4500"'),
('href="/favicon/apple-touch-icon.png"', 'href="/favicon/apple-icon-180x180.png"'),
('href="/favicon/android-chrome-192x192.png"', 'href="/favicon/android-icon-192x192.png"'),
('href="/favicon/android-chrome-256x256.png"', 'href="/favicon/android-icon-144x144.png"'),
('color="#5bbad5"', 'color="#FF4500"'),
]
for old, new in replacements:
if old not in content:
print(f'WARNING: pattern not found: {old}')
content = content.replace(old, new)
with open(path, 'w') as f:
f.write(content)
print('index.html patched successfully')