tftsr-devops_investigation/Makefile
Shaun Arman 1023d7a944 ci: migrate CI/CD from Gogs/Gitea to GitHub Actions
- Replace all .gitea/workflows with GitHub Actions equivalents
- test.yml: port full Gitea pipeline (rust-test + frontend-test jobs)
  using ghcr.io/msicie/trcaa-linux-amd64:rust1.88-node22; triggers on
  main and feature/bug/fix branches plus PRs targeting main
- release.yml: port auto-tag pipeline; switch to GITHUB_TOKEN + gh CLI
  for tagging, changelog, and artifact uploads; add macos-13 Intel build
  job alongside macos-latest ARM64; replace wiki sync to point at GitHub
  wiki; all master refs updated to main
- build-images.yml: switch registry from local Gitea to ghcr.io/msicie,
  login with GITHUB_TOKEN
- Delete pr-review.yml (qwen3-coder-next replaced by native Copilot review)
- Add .github/CODEOWNERS with @Shaun-Arman-VFK387_moto + @github-copilot
- Update Makefile: replace Gogs API/repo refs with gh CLI for uploads
- Update CLAUDE.md: wiki URL, CI/CD section, branch refs (master→main)
2026-06-01 14:03:33 -05:00

45 lines
1.5 KiB
Makefile

GH_REPO := msicie/apollo_nxt-trcaa
TAG ?= v0.1.0-alpha
TARGET := aarch64-unknown-linux-gnu
# Build linux/arm64 release artifact natively inside a Docker container,
# then upload to the GitHub release for TAG.
.PHONY: release-arm64
release-arm64: build-arm64 upload-arm64
.PHONY: build-arm64
build-arm64:
docker run --rm \
--platform linux/arm64 \
-v "$(CURDIR):/workspace" \
-w /workspace \
rust:1.88-slim \
bash -c ' \
apt-get update -qq && \
apt-get install -y -qq libwebkit2gtk-4.1-dev libssl-dev libgtk-3-dev \
libayatana-appindicator3-dev librsvg2-dev patchelf pkg-config curl perl && \
curl -fsSL https://deb.nodesource.com/setup_22.x | bash - && \
apt-get install -y nodejs && \
npm ci --legacy-peer-deps && \
rustup target add $(TARGET) && \
cargo install tauri-cli --version "^2" --locked && \
CI=true cargo tauri build --target $(TARGET) && \
mkdir -p artifacts/linux-arm64 && \
find src-tauri/target/$(TARGET)/release/bundle \
-name "*.deb" -o -name "*.rpm" -o -name "*.AppImage" | \
xargs -I{} cp {} artifacts/linux-arm64/ \
'
@echo "Artifacts:"
@ls -lh artifacts/linux-arm64/
.PHONY: upload-arm64
upload-arm64:
@test -n "$(GH_TOKEN)" || (echo "ERROR: set GH_TOKEN env var"; exit 1)
@for f in artifacts/linux-arm64/*; do \
[ -f "$$f" ] || continue; \
NAME="linux-arm64-$$(basename $$f)"; \
echo "Uploading $$NAME..."; \
GH_TOKEN=$(GH_TOKEN) gh release upload $(TAG) "$$f#$$NAME" \
--repo $(GH_REPO) && echo "OK" || echo "FAIL: $$f"; \
done