feat: add web UI with sidebar TOC and CLI args for json_to_excel

This commit is contained in:
Drunk-Youth
2026-06-29 17:08:34 +08:00
parent 8104abb37a
commit 40c74e545b
8 changed files with 1536 additions and 10 deletions
+6 -2
View File
@@ -93,7 +93,11 @@ def json_to_excel(json_file_path, output_excel_path=None):
if __name__ == '__main__':
json_path = 'sample.json'
out_path = '111.xlsx'
import sys
if len(sys.argv) < 2:
print('Usage: python json_to_excel.py <input.json> [output.xlsx]')
sys.exit(1)
json_path = sys.argv[1]
out_path = sys.argv[2] if len(sys.argv) > 2 else None
result = json_to_excel(json_path, out_path)
print(f"Excel saved to: {result}")