77 lines
2.3 KiB
YAML
77 lines
2.3 KiB
YAML
name: Fix Landwelle KI weather v1.5.68
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
paths:
|
|
- '.github/workflows/fix-news-weather-v1568.yml'
|
|
|
|
permissions:
|
|
contents: write
|
|
|
|
jobs:
|
|
fix:
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 25
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: '1.24.4'
|
|
cache: true
|
|
|
|
- name: Apply KI weather production fix
|
|
run: python3 scripts/fix-news-weather-v1568.py
|
|
|
|
- name: Format Go files
|
|
run: gofmt -w news_studio.go news_studio_sources.go news_sport_weather_sources_v1537_test.go main.go main_test.go
|
|
|
|
- name: Verify modules
|
|
run: go mod verify
|
|
|
|
- name: Test
|
|
run: go test ./...
|
|
|
|
- name: Vet
|
|
run: go vet ./...
|
|
|
|
- name: ARM64 production build
|
|
env:
|
|
CGO_ENABLED: '0'
|
|
GOOS: linux
|
|
GOARCH: arm64
|
|
run: |
|
|
go build -trimpath -o /tmp/landwelle-portal-linux-arm64 .
|
|
go build -trimpath -o /tmp/landwelle-migrate-linux-arm64 ./cmd/migrate
|
|
go build -trimpath -o /tmp/landwelle-adminpass-linux-arm64 ./cmd/adminpass
|
|
|
|
- name: Commit v1.5.68
|
|
run: |
|
|
rm -f scripts/fix-news-weather-v1568.py
|
|
rm -f .github/workflows/fix-news-weather-v1568.yml
|
|
git config user.name "github-actions[bot]"
|
|
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
|
|
git add -A
|
|
git commit -m "fix: feed live weather data into KI news studio"
|
|
git push origin HEAD:main
|
|
|
|
- name: Build complete source package
|
|
run: |
|
|
git archive --format=zip --output=/tmp/landwelle-go-portal-v1.5.68-COMPLETE-source.zip HEAD
|
|
sha256sum /tmp/landwelle-go-portal-v1.5.68-COMPLETE-source.zip > /tmp/landwelle-go-portal-v1.5.68-COMPLETE-source.sha256
|
|
|
|
- name: Upload complete source package
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: landwelle-v1.5.68-complete-source
|
|
path: |
|
|
/tmp/landwelle-go-portal-v1.5.68-COMPLETE-source.zip
|
|
/tmp/landwelle-go-portal-v1.5.68-COMPLETE-source.sha256
|
|
if-no-files-found: error
|
|
retention-days: 14
|