Skip to content

Commit 55dfa19

Browse files
committed
huh wrong import in the generator !
1 parent e8e47c1 commit 55dfa19

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

generator/layout_generator.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,8 @@
6363
\"\"\"
6464
This file was automatically generated using Circuitpython_Keyboard_Layouts
6565
\"\"\"
66-
66+
"""
67+
COMMON_HEADER_VERSION = """
6768
6869
__version__ = "0.0.0-auto.0"
6970
__repo__ = "https://github.com/Neradoc/Circuitpython_Keyboard_Layouts.git"
@@ -470,7 +471,8 @@ def make_layout_file(layout_data):
470471
"""make the layout file contents"""
471472
output_file_data = (
472473
COMMON_HEADER_COPYRIGHT
473-
+ "from keyboard_layout import KeyboardLayoutBase\n"
474+
+ "from adafruit_hid.keyboard_layout_base import KeyboardLayoutBase\n"
475+
+ COMMON_HEADER_VERSION
474476
+ f"class KeyboardLayout(KeyboardLayoutBase):\n"
475477
" ASCII_TO_KEYCODE = (\n"
476478
)
@@ -526,7 +528,7 @@ def output_layout_file(output_file, output_file_data):
526528

527529
def make_keycode_file(layout_data):
528530
"""make the keycode file contents"""
529-
output_file_data = COMMON_HEADER_COPYRIGHT + "class Keycode:\n"
531+
output_file_data = COMMON_HEADER_COPYRIGHT + COMMON_HEADER_VERSION + "class Keycode:\n"
530532

531533
def ck(x):
532534
l = x[0]

0 commit comments

Comments
 (0)