2024-07-09 09:44:03 +10:00
|
|
|
name: Build and release .deb
|
2024-01-20 20:33:25 +11:00
|
|
|
|
2024-03-03 09:53:29 +11:00
|
|
|
on:
|
2024-01-20 20:33:25 +11:00
|
|
|
push:
|
|
|
|
tags:
|
2024-07-09 09:44:03 +10:00
|
|
|
- "v[0-9]+.[0-9]+.[0-9]+"
|
2024-01-20 20:33:25 +11:00
|
|
|
|
|
|
|
jobs:
|
2024-07-09 09:44:03 +10:00
|
|
|
Build:
|
|
|
|
uses: ./.gitea/workflows/build.yaml
|
|
|
|
|
|
|
|
Release:
|
2024-03-03 09:53:29 +11:00
|
|
|
runs-on: aarch64
|
2024-01-20 20:33:25 +11:00
|
|
|
steps:
|
2024-07-09 09:44:03 +10:00
|
|
|
- name: Download artifacts
|
|
|
|
uses: actions/download-artifact@v4
|
2024-01-20 20:33:25 +11:00
|
|
|
- name: Add .deb to apt repository
|
2024-07-09 09:44:03 +10:00
|
|
|
run: "curl --user alex:${{ secrets.PACKAGING_TOKEN }} --upload-file $(ls -t ./release/*.deb | head -1) https://git.alexjanka.com/api/packages/alex/debian/pool/testing/main/upload"
|
2024-03-03 09:53:29 +11:00
|
|
|
- name: "Release package"
|
|
|
|
id: use-go-action
|
|
|
|
uses: https://gitea.com/actions/release-action@main
|
|
|
|
with:
|
|
|
|
files: |-
|
|
|
|
./target/aarch64-unknown-linux-gnu/debian/*.deb
|
|
|
|
./target/aarch64-unknown-linux-gnu/release/tesla-charge-controller
|
|
|
|
api_key: "${{secrets.PACKAGING_TOKEN}}"
|