Compare commits
21 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| aecd02e850 | |||
| 5019970d01 | |||
| 446547df04 | |||
| dea98e71b8 | |||
| ea62fa1cec | |||
| 32129ee5a2 | |||
| 6638c13c36 | |||
| 98ab6a52f6 | |||
| f9d3020616 | |||
| 1c98cf7053 | |||
| 6b98cb311f | |||
| 8a4bf2d437 | |||
| db645b7db8 | |||
| 3f4c491202 | |||
| 39d3adddff | |||
| d557058db7 | |||
| 3126bdb90a | |||
| d2f73683f8 | |||
| 83978d4c68 | |||
| bb00940631 | |||
| 29bcd3aa01 |
+1
-1
@@ -1,5 +1,5 @@
|
|||||||
[bumpversion]
|
[bumpversion]
|
||||||
current_version = 1.1.1
|
current_version = 1.1.2
|
||||||
commit = True
|
commit = True
|
||||||
tag = True
|
tag = True
|
||||||
tag_name = {new_version}
|
tag_name = {new_version}
|
||||||
|
|||||||
@@ -7,7 +7,25 @@ on:
|
|||||||
pull_request:
|
pull_request:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
test_cli_base_container:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container: ghcr.io/qmk/qmk_base_container
|
||||||
|
|
||||||
|
env:
|
||||||
|
QMK_HOME: ~/qmk_firmware
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: apt-get update && apt-get install -y python3-venv
|
||||||
|
|
||||||
|
- name: Run ci_tests
|
||||||
|
run: ./ci_tests -a
|
||||||
|
|
||||||
test_cli_linux_macos:
|
test_cli_linux_macos:
|
||||||
|
needs: test_cli_base_container
|
||||||
|
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
env:
|
env:
|
||||||
QMK_HOME: ~/qmk_firmware
|
QMK_HOME: ~/qmk_firmware
|
||||||
@@ -28,6 +46,8 @@ jobs:
|
|||||||
run: ./ci_tests -a
|
run: ./ci_tests -a
|
||||||
|
|
||||||
test_cli_win:
|
test_cli_win:
|
||||||
|
needs: test_cli_base_container
|
||||||
|
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
env:
|
env:
|
||||||
QMK_HOME: $HOME/qmk_firmware
|
QMK_HOME: $HOME/qmk_firmware
|
||||||
|
|||||||
@@ -13,23 +13,44 @@ jobs:
|
|||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: '3.7'
|
python-version: '3.7'
|
||||||
|
|
||||||
|
- name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v2
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v2
|
||||||
|
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
- name: 'Get Previous tag'
|
- name: 'Get Previous tag'
|
||||||
id: previoustag
|
id: previoustag
|
||||||
uses: "WyriHaximus/github-action-get-previous-tag@v1"
|
uses: "WyriHaximus/github-action-get-previous-tag@v1"
|
||||||
|
|
||||||
- name: Download previous artifact
|
- name: Download previous artifact
|
||||||
run: |
|
run: |
|
||||||
pip download -d "${GITHUB_WORKSPACE}/dist" qmk=="${{ steps.previoustag.outputs.tag }}"
|
pip download -d "${GITHUB_WORKSPACE}/dist" qmk=="${{ steps.previoustag.outputs.tag }}"
|
||||||
|
|
||||||
|
- name: Login to GitHub Container Registry
|
||||||
|
uses: docker/login-action@v2
|
||||||
|
with:
|
||||||
|
registry: ghcr.io
|
||||||
|
username: ${{ github.repository_owner }}
|
||||||
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Log in to Docker Hub
|
- name: Log in to Docker Hub
|
||||||
uses: docker/login-action@v2.0.0
|
uses: docker/login-action@v2.1.0
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKER_HUB_USERNAME }}
|
username: ${{ secrets.DOCKER_HUB_USERNAME }}
|
||||||
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
|
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
|
||||||
|
|
||||||
- name: Build and Push to Docker Hub
|
- name: Build and Push to Docker Hub
|
||||||
uses: docker/build-push-action@v3.1.1
|
uses: docker/build-push-action@v4.0.0
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
push: true
|
push: true
|
||||||
tags: qmkfm/qmk_cli:latest
|
platforms: linux/amd64,linux/arm64
|
||||||
|
tags: |
|
||||||
|
ghcr.io/qmk/qmk_cli:latest
|
||||||
|
qmkfm/qmk_cli:latest
|
||||||
|
|||||||
@@ -17,29 +17,41 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
|
||||||
- name: Set up Python
|
- name: Set up Python
|
||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: '3.7'
|
python-version: '3.7'
|
||||||
|
|
||||||
|
- name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v2
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v2
|
||||||
|
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Run ci_tests
|
- name: Run ci_tests
|
||||||
run: ./ci_tests
|
run: ./ci_tests
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
python3 -m pip install --upgrade pip
|
python3 -m pip install --upgrade pip
|
||||||
pip install setuptools wheel
|
pip install setuptools wheel
|
||||||
pip install -r requirements-dev.txt
|
pip install -r requirements-dev.txt
|
||||||
|
|
||||||
- name: Bump version
|
- name: Bump version
|
||||||
run: |
|
run: |
|
||||||
git config --local user.email "hello@qmk.fm"
|
git config --local user.email "hello@qmk.fm"
|
||||||
git config --local user.name "QMK Bot"
|
git config --local user.name "QMK Bot"
|
||||||
bumpversion ${{ github.event.inputs.version_part }}
|
bumpversion ${{ github.event.inputs.version_part }}
|
||||||
|
|
||||||
- name: Push changes
|
- name: Push changes
|
||||||
uses: ad-m/github-push-action@master
|
uses: ad-m/github-push-action@master
|
||||||
with:
|
with:
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
branch: master
|
branch: master
|
||||||
tags: true
|
tags: true
|
||||||
|
|
||||||
- name: Build and publish
|
- name: Build and publish
|
||||||
env:
|
env:
|
||||||
TWINE_USERNAME: qmk
|
TWINE_USERNAME: qmk
|
||||||
@@ -47,17 +59,30 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
python3 -m build
|
python3 -m build
|
||||||
twine upload dist/*
|
twine upload dist/*
|
||||||
|
|
||||||
|
- name: Login to GitHub Container Registry
|
||||||
|
uses: docker/login-action@v2
|
||||||
|
with:
|
||||||
|
registry: ghcr.io
|
||||||
|
username: ${{ github.repository_owner }}
|
||||||
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Log in to Docker Hub
|
- name: Log in to Docker Hub
|
||||||
uses: docker/login-action@v2.0.0
|
uses: docker/login-action@v2.1.0
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKER_HUB_USERNAME }}
|
username: ${{ secrets.DOCKER_HUB_USERNAME }}
|
||||||
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
|
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
|
||||||
|
|
||||||
- name: Build and Push to Docker Hub
|
- name: Build and Push to Docker Hub
|
||||||
uses: docker/build-push-action@v3.1.1
|
uses: docker/build-push-action@v4.0.0
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
push: true
|
push: true
|
||||||
tags: qmkfm/qmk_cli:latest
|
platforms: linux/amd64,linux/arm64
|
||||||
|
tags: |
|
||||||
|
ghcr.io/qmk/qmk_cli:latest
|
||||||
|
qmkfm/qmk_cli:latest
|
||||||
|
|
||||||
- name: Trigger OS package builds
|
- name: Trigger OS package builds
|
||||||
run: ./trigger_packages
|
run: ./trigger_packages
|
||||||
env:
|
env:
|
||||||
|
|||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
FROM qmkfm/base_container
|
FROM ghcr.io/qmk/qmk_base_container:latest
|
||||||
|
|
||||||
# Copy package in
|
# Copy package in
|
||||||
ADD dist /tmp/dist
|
ADD dist /tmp/dist
|
||||||
|
|||||||
+1
-1
@@ -1,3 +1,3 @@
|
|||||||
"""A program to help you work with qmk_firmware."""
|
"""A program to help you work with qmk_firmware."""
|
||||||
|
|
||||||
__version__ = '1.1.1'
|
__version__ = '1.1.2'
|
||||||
|
|||||||
@@ -23,7 +23,8 @@ def clone(cli):
|
|||||||
qmk_firmware = Path(cli.args.destination)
|
qmk_firmware = Path(cli.args.destination)
|
||||||
git_url = '/'.join((cli.args.baseurl, cli.args.fork))
|
git_url = '/'.join((cli.args.baseurl, cli.args.fork))
|
||||||
|
|
||||||
if qmk_firmware.exists():
|
# Exists (but not an empty dir)
|
||||||
|
if qmk_firmware.exists() and any(qmk_firmware.iterdir()):
|
||||||
cli.log.error('Destination already exists: %s', cli.args.destination)
|
cli.log.error('Destination already exists: %s', cli.args.destination)
|
||||||
exit(1)
|
exit(1)
|
||||||
|
|
||||||
|
|||||||
@@ -142,7 +142,7 @@ class MonitorDevice(object):
|
|||||||
message['identifier'] = ':'.join(identifier)
|
message['identifier'] = ':'.join(identifier)
|
||||||
message['ts'] = '{style_dim}{fg_green}%s{style_reset_all} ' % (strftime(cli.config.general.datetime_fmt),) if cli.args.timestamp else ''
|
message['ts'] = '{style_dim}{fg_green}%s{style_reset_all} ' % (strftime(cli.config.general.datetime_fmt),) if cli.args.timestamp else ''
|
||||||
|
|
||||||
cli.echo('%(ts)s%(color)s%(identifier)s:%(index)d{style_reset_all}: %(text)s' % message)
|
cli.echo('%s', '%(ts)s%(color)s%(identifier)s:%(index)d{style_reset_all}: %(text)s' % message)
|
||||||
|
|
||||||
except self.hid.HIDException:
|
except self.hid.HIDException:
|
||||||
break
|
break
|
||||||
|
|||||||
@@ -65,7 +65,8 @@ def setup(cli):
|
|||||||
if is_qmk_firmware(cli.args.home):
|
if is_qmk_firmware(cli.args.home):
|
||||||
cli.log.info('Found qmk_firmware at %s.', str(cli.args.home))
|
cli.log.info('Found qmk_firmware at %s.', str(cli.args.home))
|
||||||
|
|
||||||
elif cli.args.home.exists():
|
# Exists (but not an empty dir)
|
||||||
|
elif cli.args.home.exists() and any(cli.args.home.iterdir()):
|
||||||
path_str = str(cli.args.home)
|
path_str = str(cli.args.home)
|
||||||
|
|
||||||
if cli.args.home.name != 'qmk_firmware':
|
if cli.args.home.name != 'qmk_firmware':
|
||||||
@@ -104,4 +105,4 @@ def setup(cli):
|
|||||||
if cli.args.yes:
|
if cli.args.yes:
|
||||||
doctor_command.append('-y')
|
doctor_command.append('-y')
|
||||||
|
|
||||||
cli.run(doctor_command, stdin=None, capture_output=False)
|
cli.run(doctor_command, stdin=None, capture_output=False, cwd=cli.args.home)
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ ignore = E501,E226
|
|||||||
|
|
||||||
[metadata]
|
[metadata]
|
||||||
name = qmk
|
name = qmk
|
||||||
version = 1.1.1
|
version = 1.1.2
|
||||||
author = skullydazed
|
author = skullydazed
|
||||||
author_email = skullydazed@gmail.com
|
author_email = skullydazed@gmail.com
|
||||||
description = A program to help users work with QMK Firmware.
|
description = A program to help users work with QMK Firmware.
|
||||||
|
|||||||
Reference in New Issue
Block a user