kind: pipeline
name: default

steps:
- name: build
  image: python:3
  commands:
  - pip install platformio
  - pio run
- name: upload
  image: python:3
  commands:
  - make otaupload
  when:
    event: tag
- name: release
  image: plugins/gitea-release
  settings:
    api_key: a7f3afc9f77e721951e48b4af66d7565700b7a2e
    base_url: https://code.jcktrue.dk
    files:
      - .pio/build/nodemcu/firmware.bin
      - .pio/build/nodemcu/firmware.elf
  when:
    event: tag
