|
@@ -17,8 +17,8 @@ jobs:
|
|
|
lint:
|
|
lint:
|
|
|
runs-on: ubuntu-latest
|
|
runs-on: ubuntu-latest
|
|
|
steps:
|
|
steps:
|
|
|
- - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
|
|
|
- - uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
|
|
|
|
|
|
|
+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
|
|
|
|
|
+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6.3.0
|
|
|
with:
|
|
with:
|
|
|
python-version: "3.13"
|
|
python-version: "3.13"
|
|
|
- uses: pre-commit/action@2c7b3805fd2a0fd8c1884dcaebf91fc102a13ecd # v3.0.1
|
|
- uses: pre-commit/action@2c7b3805fd2a0fd8c1884dcaebf91fc102a13ecd # v3.0.1
|
|
@@ -36,23 +36,23 @@ jobs:
|
|
|
- ubuntu-latest
|
|
- ubuntu-latest
|
|
|
runs-on: ${{ matrix.os }}
|
|
runs-on: ${{ matrix.os }}
|
|
|
steps:
|
|
steps:
|
|
|
- - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
|
|
|
|
|
+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
|
|
|
- name: Set up uv
|
|
- name: Set up uv
|
|
|
- uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
|
|
|
|
|
|
|
+ uses: astral-sh/setup-uv@fac544c07dec837d0ccb6301d7b5580bf5edae39 # v8.2.0
|
|
|
with:
|
|
with:
|
|
|
enable-cache: true
|
|
enable-cache: true
|
|
|
- name: Install poetry
|
|
- name: Install poetry
|
|
|
run: uv tool install poetry
|
|
run: uv tool install poetry
|
|
|
- name: Set up Python
|
|
- name: Set up Python
|
|
|
id: setup-python
|
|
id: setup-python
|
|
|
- uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
|
|
|
|
|
|
|
+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6.3.0
|
|
|
with:
|
|
with:
|
|
|
python-version: ${{ matrix.python-version }}
|
|
python-version: ${{ matrix.python-version }}
|
|
|
cache: "poetry"
|
|
cache: "poetry"
|
|
|
allow-prereleases: true
|
|
allow-prereleases: true
|
|
|
- name: Cache poetry venv
|
|
- name: Cache poetry venv
|
|
|
id: cache-venv
|
|
id: cache-venv
|
|
|
- uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
|
|
|
|
|
|
|
+ uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
|
|
|
with:
|
|
with:
|
|
|
path: .venv
|
|
path: .venv
|
|
|
key: venv-v1-${{ runner.os }}-py${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('poetry.lock', 'pyproject.toml') }}
|
|
key: venv-v1-${{ runner.os }}-py${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('poetry.lock', 'pyproject.toml') }}
|
|
@@ -62,7 +62,7 @@ jobs:
|
|
|
- name: Test with Pytest
|
|
- name: Test with Pytest
|
|
|
run: poetry run pytest --cov=switchbot --cov-report=xml --durations=30 tests
|
|
run: poetry run pytest --cov=switchbot --cov-report=xml --durations=30 tests
|
|
|
- name: Upload coverage to Codecov
|
|
- name: Upload coverage to Codecov
|
|
|
- uses: codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2 # v6.0.0
|
|
|
|
|
|
|
+ uses: codecov/codecov-action@fb8b3582c8e4def4969c97caa2f19720cb33a72f # v7.0.0
|
|
|
with:
|
|
with:
|
|
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
|
|
|
|
|
@@ -80,7 +80,7 @@ jobs:
|
|
|
contents: read
|
|
contents: read
|
|
|
|
|
|
|
|
steps:
|
|
steps:
|
|
|
- - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
|
|
|
|
|
+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
|
|
|
with:
|
|
with:
|
|
|
fetch-depth: 0
|
|
fetch-depth: 0
|
|
|
ref: ${{ github.ref }}
|
|
ref: ${{ github.ref }}
|
|
@@ -127,7 +127,7 @@ jobs:
|
|
|
app-id: ${{ secrets.RELEASE_APP_ID }}
|
|
app-id: ${{ secrets.RELEASE_APP_ID }}
|
|
|
private-key: ${{ secrets.RELEASE_APP_PRIVATE_KEY }}
|
|
private-key: ${{ secrets.RELEASE_APP_PRIVATE_KEY }}
|
|
|
|
|
|
|
|
- - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
|
|
|
|
|
+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
|
|
|
with:
|
|
with:
|
|
|
fetch-depth: 0
|
|
fetch-depth: 0
|
|
|
ref: ${{ github.ref }}
|
|
ref: ${{ github.ref }}
|