README / Telegram_Job_Bot /extract.py
nmnm969989's picture
Upload 550 files
ece3e8e verified
Raw History Blame Contribute Delete
403 Bytes
with open('main.py', 'r', encoding='utf-8') as f:
lines = f.readlines()
start_idx = 2635
end_idx = 3266
html_lines = lines[start_idx:end_idx]
html_lines[0] = html_lines[0].replace(' return f\"\"\"', '')
html_lines[-1] = html_lines[-1].replace('\"\"\"\n', '\n')
with open('templates/dashboard.html', 'w', encoding='utf-8') as f:
f.writelines(html_lines)
print('Extracted dashboard.html')