def METHOD_NAME(kb):
    """Check the keyboard-level rules.mk to ensure it only has assignments.
    """
    keyboard_path = keyboard(kb)
    current_path = Path()
    errors = []
    for path_part in keyboard_path.parts:
        current_path = current_path / path_part
        rules_mk = current_path / 'rules.mk'
        if rules_mk.exists():
            continuation = None
            for i, line in enumerate(rules_mk.open()):
                line = line.strip()
                if '#' in line:
                    line = line[:line.index('#')]
                if continuation:
                    line = continuation + line
                    continuation = None
                if line:
                    if line[-1] == '\\':
                        continuation = line[:-1]
                        continue
                    if line and '=' not in line:
                        errors.append(f'Non-assignment code on line +{i} {rules_mk}: {line}')
    return errors