Skip to content

feat: cli add schema details and storage support #86

feat: cli add schema details and storage support

feat: cli add schema details and storage support #86

Workflow file for this run

# Parity workflow: CI parity checks and build artifacts for PRs, pushes, schedules,
# and manual preview builds.
name: parity
on:
pull_request:
push:
branches:
- main
workflow_dispatch:
schedule:
- cron: "0 9 * * 1"
jobs:
parity:
runs-on: ubuntu-latest
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Checkout upstream Apprise
run: |
set -euo pipefail
upstream_version=$(sed -n 's/^var UpstreamVersion = "\([^"]*\)"/\1/p' internal/version/version.go)
if [[ -z "${upstream_version}" ]]; then
echo "UpstreamVersion not found in internal/version/version.go" >&2
exit 1
fi
target="../apprise"
if [[ -d "${target}" ]] && ([[ -d "${target}/.git" ]] || git -C "${target}" rev-parse --is-inside-work-tree >/dev/null 2>&1); then
echo "Upstream apprise repo already present at ${target}"
exit 0
fi
mkdir -p "${target}"
git -C "${target}" init
git -C "${target}" remote add origin https://github.com/caronc/apprise
if git -C "${target}" fetch --depth 1 origin "refs/tags/v${upstream_version}"; then
git -C "${target}" checkout --detach FETCH_HEAD
elif git -C "${target}" fetch --depth 1 origin "refs/tags/${upstream_version}"; then
git -C "${target}" checkout --detach FETCH_HEAD
else
echo "Upstream tag not found for version ${upstream_version}." >&2
exit 1
fi
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.14"
- name: Install parity dependencies
run: bash scripts/ci/setup_parity_env.sh
- name: Run parity tests
run: bash scripts/ci/run_parity_tests.sh
- name: Notify Discord on scheduled parity failure
if: failure() && github.event_name == 'schedule' && env.DISCORD_WEBHOOK != ''
run: |
run_url="https://github.com/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}"
payload=$(printf '{"content":"parity cron failed for %s: %s"}' "$GITHUB_REPOSITORY" "$run_url")
curl -sS -X POST -H "Content-Type: application/json" -d "$payload" "$DISCORD_WEBHOOK"
build:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- goos: linux
goarch: amd64
ext: ""
- goos: linux
goarch: arm64
ext: ""
- goos: darwin
goarch: amd64
ext: ""
- goos: darwin
goarch: arm64
ext: ""
- goos: windows
goarch: amd64
ext: ".exe"
- goos: windows
goarch: arm64
ext: ".exe"
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
- name: Build binary
env:
GOOS: ${{ matrix.goos }}
GOARCH: ${{ matrix.goarch }}
CGO_ENABLED: "0"
BIN_EXT: ${{ matrix.ext }}
run: |
mkdir -p dist
go build -trimpath -ldflags "-s -w" -o "dist/apprise-go-${GOOS}-${GOARCH}${BIN_EXT}" ./cmd/apprise
- name: Upload binary artifact
uses: actions/upload-artifact@v6
with:
name: apprise-go-${{ matrix.goos }}-${{ matrix.goarch }}${{ matrix.ext }}
path: dist/apprise-go-${{ matrix.goos }}-${{ matrix.goarch }}${{ matrix.ext }}