-
-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (42 loc) · 1.36 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
on:
push:
branches:
- main
permissions:
contents: write
pull-requests: write
name: release-please
jobs:
release-please:
runs-on: ubuntu-22.04
steps:
# Add packages to update into release-please-config.json
- name: Write new version to packages
id: release
uses: google-github-actions/release-please-action@v4
with:
token: ${{ secrets.MAINTAINER_PAT }}
target-branch: ${{ github.ref_name }}
# Steps bellow occurs only when a version is created
- uses: actions/checkout@v4
if: ${{ steps.release.outputs.release_created }}
- name: Cache pio and pip
if: ${{ steps.release.outputs.release_created }}
uses: actions/cache@v3
with:
path: |
~/.cache/pip
~/.platformio/.cache
key: ${{ runner.os }}-pio
- uses: actions/setup-python@v4
if: ${{ steps.release.outputs.release_created }}
with:
python-version: '3.9'
- name: Install PlatformIO Core
if: ${{ steps.release.outputs.release_created }}
run: pip install --upgrade platformio
- name: PlatformIO publish
if: ${{ steps.release.outputs.release_created }}
env:
PLATFORMIO_AUTH_TOKEN: ${{ secrets.PIO_PAT }}
run: pio package publish --type library --no-interactive