Stop mirroring builds and main to the deleted Forgejo repository.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
pepaskopec-blip 2026-09-25 15:57:23 +02:00
commit 7f989691a2
3 changed files with 5 additions and 61 deletions

View file

@ -264,13 +264,8 @@ jobs:
# The branch is rewritten from scratch every time rather than added to, # The branch is rewritten from scratch every time rather than added to,
# so the repository keeps one copy of the packages instead of a new # so the repository keeps one copy of the packages instead of a new
# ~70 MB set per commit. The same commit is then mirrored to Forgejo # ~70 MB set per commit.
# when FORGEJO_TOKEN is set (git.dvorakmortonxd.dev).
- name: Push to builds branch - name: Push to builds branch
env:
FORGEJO_TOKEN: ${{ secrets.FORGEJO_TOKEN }}
FORGEJO_USER: ${{ secrets.FORGEJO_USER }}
FORGEJO_URL: ${{ secrets.FORGEJO_URL }}
run: | run: |
git config user.name "github-actions[bot]" git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
@ -285,52 +280,3 @@ jobs:
git add -A git add -A
git commit -q -m "Build from ${{ github.sha }}" git commit -q -m "Build from ${{ github.sha }}"
git push -f origin builds git push -f origin builds
if [ -z "${FORGEJO_TOKEN:-}" ]; then
echo "No FORGEJO_TOKEN; skipping Forgejo builds publish."
exit 0
fi
# Prefer Basic auth over URL userinfo so tokens with @/: never
# break the URL. Force-push: this is a one-way GitHub → Forgejo
# mirror (repo moved to edu/; non-ff rejects otherwise).
token="$(printf '%s' "$FORGEJO_TOKEN" | tr -d '\r\n')"
user="$(printf '%s' "${FORGEJO_USER:-}" | tr -d '\r\n')"
user="${user:-oauth2}"
basic="$(printf '%s:%s' "$user" "$token" | base64 -w0)"
forgejo_url="${FORGEJO_URL:-https://git.dvorakmortonxd.dev/edu/Graduately.git}"
git -c "http.extraHeader=Authorization: Basic ${basic}" push -f \
"$forgejo_url" \
HEAD:refs/heads/builds
forgejo-main:
name: Mirror main to Forgejo
runs-on: ubuntu-latest
steps:
# Full history: Forgejo rejects "shallow update" when replacing main.
- uses: actions/checkout@v4
with:
fetch-depth: 0
# Same rule as the macOS cert step: never put `secrets` in `if:`.
- name: Push main
env:
FORGEJO_TOKEN: ${{ secrets.FORGEJO_TOKEN }}
FORGEJO_USER: ${{ secrets.FORGEJO_USER }}
FORGEJO_URL: ${{ secrets.FORGEJO_URL }}
run: |
set -euo pipefail
token="$(printf '%s' "${FORGEJO_TOKEN:-}" | tr -d '\r\n')"
if [ -z "$token" ]; then
echo "No FORGEJO_TOKEN; skipping Forgejo main mirror."
exit 0
fi
# Belt-and-suspenders if a future checkout change re-shallows.
if git rev-parse --is-shallow-repository 2>/dev/null | grep -qx true; then
git fetch --unshallow origin
fi
user="$(printf '%s' "${FORGEJO_USER:-}" | tr -d '\r\n')"
user="${user:-oauth2}"
basic="$(printf '%s:%s' "$user" "$token" | base64 -w0)"
forgejo_url="${FORGEJO_URL:-https://git.dvorakmortonxd.dev/edu/Graduately.git}"
git -c "http.extraHeader=Authorization: Basic ${basic}" push -f \
"$forgejo_url" \
HEAD:refs/heads/main

View file

@ -161,7 +161,7 @@ data/ style.css, changelog.txt, share/, cetba/*.json
assets/ zdrojová ikona a screenshoty assets/ zdrojová ikona a screenshoty
installers/ instalátory, které stáhnou aktuální build installers/ instalátory, které stáhnou aktuální build
scripts/ balení AppImage, .app, IPA, extract a smoke test scripts/ balení AppImage, .app, IPA, extract a smoke test
.github/workflows/ CI: push na main → větev builds (+ zrcadlo Forgejo) .github/workflows/ CI: push na main → větev builds
progress/ vzniká za běhu (cvičení, nastavení) progress/ vzniká za běhu (cvičení, nastavení)
``` ```
@ -355,7 +355,7 @@ data/ style.css, changelog.txt, share/, cetba/*.json
assets/ source icon and screenshots assets/ source icon and screenshots
installers/ fetch-the-latest installers installers/ fetch-the-latest installers
scripts/ AppImage / .app / IPA bundlers, extract, smoke test scripts/ AppImage / .app / IPA bundlers, extract, smoke test
.github/workflows/ CI: push to main → builds branch (+ Forgejo mirror) .github/workflows/ CI: push to main → builds branch
progress/ created at runtime (exercises, settings) progress/ created at runtime (exercises, settings)
``` ```

View file

@ -7,7 +7,7 @@
# en: bullet # en: bullet
--- 2026-09-23 --- 2026-09-23
cs: Repozitář se jmenuje Graduately (GitHub i Forgejo); instalátory a updater míří tam cs: Repozitář se jmenuje Graduately; instalátory a updater míří tam
cs: Balíčky a instalátory se jmenují graduately-* (už ne maturita-*) cs: Balíčky a instalátory se jmenují graduately-* (už ne maturita-*)
cs: Aplikace se jmenuje Graduately; úvod stále říká „Maturita? To dáme.“ cs: Aplikace se jmenuje Graduately; úvod stále říká „Maturita? To dáme.“
cs: Kompletní maturitní četba (82 knih) se zápisky, kvízem a sestavením děje cs: Kompletní maturitní četba (82 knih) se zápisky, kvízem a sestavením děje
@ -15,8 +15,7 @@ cs: Studium knih: nejdřív procvičení (kvíz / sestavte děj), pak zápisky
cs: Kvíz a sestavení děje u všech knih i na GTK (Linux / Windows) cs: Kvíz a sestavení děje u všech knih i na GTK (Linux / Windows)
cs: Větší a čitelnější rozhraní na Macu cs: Větší a čitelnější rozhraní na Macu
cs: Opravy výběru slov v dialogu a otevření knihy z vyhledávání cs: Opravy výběru slov v dialogu a otevření knihy z vyhledávání
cs: Oprava zrcadlení na Forgejo (edu/Graduately, plná historie, force-push) en: Repository renamed to Graduately; installers and updater follow
en: Repository renamed to Graduately (GitHub and Forgejo); installers and updater follow
en: Packages and installers are now graduately-* (no more maturita-*) en: Packages and installers are now graduately-* (no more maturita-*)
en: The app is now Graduately; the welcome line still says “Maturita? We've got this.” en: The app is now Graduately; the welcome line still says “Maturita? We've got this.”
en: Full maturita reading list (82 books) with notes, quiz, and plot ordering en: Full maturita reading list (82 books) with notes, quiz, and plot ordering
@ -24,7 +23,6 @@ en: Book study flow: practice first (quiz / order the plot), then notes
en: Quiz and plot assembly for every book on GTK too (Linux / Windows) en: Quiz and plot assembly for every book on GTK too (Linux / Windows)
en: Larger, more readable Mac interface en: Larger, more readable Mac interface
en: Fixes for dialogue word picking and opening a book from search en: Fixes for dialogue word picking and opening a book from search
en: Forgejo mirror fix (edu/Graduately, full history, force-push)
--- 2026-09-18 --- 2026-09-18
cs: Po aktualizaci se na hlavní stránce ukáže, co je nového cs: Po aktualizaci se na hlavní stránce ukáže, co je nového