Skip to content

Commit 389a927

Browse files
committed
real boot.py
1 parent 1e7762a commit 389a927

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

misc_file_changes.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,7 @@ def filesystem_file():
2424
file_path = "./cpy/circuitpython/supervisor/shared/filesystem.c"
2525
find_and_replace_in_file(file_path,'"CIRCUITPY")','"BSPYTHON")')
2626
find_and_replace_in_file(file_path,'const byte buffer[] = "print(\\"Hello World!\\")\\n";','const byte buffer[] = "from kmk.json_keymap import JsonMap\\nkeyboard = JsonMap(\\"layout.json\\").return_keyboard()\\nif __name__ == \\"__main__\\":\\n keyboard.go()\\n";')
27-
find_and_replace_in_file(file_path,'// Create or modify existing code.py file','const byte buffer2[] = "print(\\"Hello World!\\")\\n";\n f_open(fatfs, &fs, "/boot.py", FA_WRITE | FA_CREATE_ALWAYS);\n f_write(&fs, buffer2, sizeof(buffer2) - 1, &char_written);\n f_close(&fs);\n')
28-
27+
find_and_replace_in_file(file_path,'// Create or modify existing code.py file','const byte buffer2[] = "from kmk.json_boot import JsonBoot\\nboot = JsonBoot(\\"layout.json\\")\\n";\n f_open(fatfs, &fs, "/boot.py", FA_WRITE | FA_CREATE_ALWAYS);\n f_write(&fs, buffer2, sizeof(buffer2) - 1, &char_written);\n f_close(&fs);\n')
2928
def do_all_the_changes():
3029
supervisor_file()
3130
filesystem_file()

0 commit comments

Comments
 (0)