From a15a50ba4d34c9ee37700744fb54eaaaaa909ad5 Mon Sep 17 00:00:00 2001 From: Nick Brassel Date: Thu, 27 Nov 2025 22:34:04 +1100 Subject: [PATCH 1/2] Align QMK distrib search with `qmk_firmware`. --- qmk_cli/script_qmk.py | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/qmk_cli/script_qmk.py b/qmk_cli/script_qmk.py index 420f29e..85d990a 100644 --- a/qmk_cli/script_qmk.py +++ b/qmk_cli/script_qmk.py @@ -17,9 +17,21 @@ from . import __version__ from .helpers import find_qmk_firmware, is_qmk_firmware, find_qmk_userspace, is_qmk_userspace + +def _get_default_distrib_path(): + if 'windows' in platform().lower(): + try: + result = milc.cli.run(['cygpath', '-w', '/opt/qmk']) + if result.returncode == 0: + return result.stdout.strip() + except Exception: + pass + + return platformdirs.user_data_dir('qmk') + + # Ensure the QMK distribution is on the `$PATH` if present. This must be kept in sync with qmk/qmk_firmware. -_default_distrib_path = milc.cli.run(['cygpath', '-w', '/opt/qmk']).stdout.strip() if 'windows' in platform().lower() else platformdirs.user_data_dir('qmk') # this must be kept in sync with the default values inside `util/env-bootstrap.sh`! -QMK_DISTRIB_DIR = Path(os.environ.get('QMK_DISTRIB_DIR', _default_distrib_path)) +QMK_DISTRIB_DIR = Path(os.environ.get('QMK_DISTRIB_DIR', _get_default_distrib_path())) if QMK_DISTRIB_DIR.exists(): os.environ['PATH'] = str(QMK_DISTRIB_DIR / 'bin') + os.pathsep + os.environ['PATH'] From 73486eb4eaef6d3750a408bd17bbecf0a967c4a5 Mon Sep 17 00:00:00 2001 From: Nick Brassel Date: Thu, 27 Nov 2025 23:06:15 +1100 Subject: [PATCH 2/2] Use newer versions of Python during CI builds. --- .github/workflows/cli_setup.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cli_setup.yml b/.github/workflows/cli_setup.yml index 145ae82..500e508 100644 --- a/.github/workflows/cli_setup.yml +++ b/.github/workflows/cli_setup.yml @@ -32,7 +32,7 @@ jobs: strategy: matrix: os: [macos-latest, ubuntu-latest] - python-version: ['3.9', '3.10', '3.11', '3.12'] + python-version: ['3.9', '3.10', '3.11', '3.12', '3.13', '3.14'] steps: - uses: actions/checkout@v6