gitoria

notes

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commita2e343aea2e343aeident selector back in the header (creator 2026-10-24): selector top right signed in and out on phone and desktop, no second Log in button, new gate checks (WIP: gates not re-run after the last edits)mrea2e343ae/tools/sync-components.sh

1.9 KB

  1. #!/usr/bin/env bash
  2. # tools/sync-components.sh — copy the components.hybriel.worldapi.org blocks notes uses, BYTE-VERBATIM from a commit
  3. # (mission 010; the model is layouts.worldapi.org's tools/sync-components.sh).
  4. # tools/sync-components.sh [commit] copy from <commit> (default: HEAD of the source repo), write components/SOURCE
  5. # tools/sync-components.sh --check compare the copies with the commit in components/SOURCE (exit 1 on any difference)
  6. # Source repo: $COMPONENTS_REPO (default loreana /media/STORAGE/projects/WorldAPI/components.hybriel.worldapi.org). The files come out of
  7. # git (`git show <commit>:<path>`), not the working tree, so uncommitted edits there never land here. Never edit the copies:
  8. # change them in components.hybriel, commit there, run this, then the gates (README "Files").
  9. set -euo pipefail
  10. APP="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
  11. SRC="${COMPONENTS_REPO:-/media/STORAGE/projects/WorldAPI/components.hybriel.worldapi.org}"
  12. # what is copied: the MdEditor block's own file + README (no demo.hl).
  13. FILES=(
  14. md-editor/md-editor.hl md-editor/README.md
  15. icons/icons.hl icons/README.md
  16. )
  17. # a git worktree has a .git FILE, a clone a .git directory: either is a repo
  18. [ -e "$SRC/.git" ] || { echo "no git repo at $SRC (set COMPONENTS_REPO)"; exit 2; }
  19. if [ "${1:-}" = "--check" ]; then
  20. REF="$(head -n1 "$APP/components/SOURCE" | cut -d' ' -f1)"
  21. bad=0
  22. for f in "${FILES[@]}"; do
  23. if ! git -C "$SRC" show "$REF:components/$f" | cmp -s - "$APP/components/$f"; then echo "DIFFERS: components/$f (vs $REF)"; bad=1; fi
  24. done
  25. [ $bad = 0 ] && echo "verbatim: ${#FILES[@]} files = components.hybriel $REF"
  26. exit $bad
  27. fi
  28. REF="$(git -C "$SRC" rev-parse --short "${1:-HEAD}^{commit}")"
  29. for f in "${FILES[@]}"; do
  30. mkdir -p "$APP/components/$(dirname "$f")"
  31. git -C "$SRC" show "$REF:components/$f" > "$APP/components/$f"
  32. done
  33. echo "$REF $(git -C "$SRC" log -1 --format='%cs %s' "$REF")" > "$APP/components/SOURCE"
  34. echo "copied ${#FILES[@]} files from components.hybriel $REF"
  35. "$0" --check

Branches

Latest commits

  • a2e343aeident selector back in the header (creator 2026-10-24): selector top right signed in and out on phone and desktop, no second Log in button, new gate checks (WIP: gates not re-run after the last edits)mre
  • b96c7f70theme: sync from layouts 4994037 (list rows stack, td word-keep, heading code, edited tap target)mre
  • 6140e6a0sessions last 99 years (creator 2026-10-23: logins never expire; only sign out ends them)mre
  • cb7e6469deploy: security gate (tests/security.mjs)mre
  • 774bf34bnotes security: CSRF guard on /api/notes, new session at login, Secure cookie, uploadMax 0, login rate limit, nosniff, face payload check; tests/security.mjs; SN reportmre
  • ef18a68fsync components.hybriel 214c318: MdEditor on a phone, two even toolbar rows of 44 px targets, label 15 px, table head 16 px (E2)mre
  • c37488b1MN report: alignment updatemre
  • 4fb35a0enotes mobile: Delete note and the delete row exactly on the editor's edges; gate asserts 1 pxmre
  • 91736270MN report and logmre
  • 15667425notes: delete confirmation buttons at most 12rem wide on the desktopmre
  • 8f7a6a95gate: MN phone checks (list header gutter, back gap, delete question)mre
  • 90c73ed3notes mobile: back link gapmre
  • 72bd4f83notes mobile: list header on the gutter, delete confirmation as a question + two equal buttons, Delete note under the editor edgemre
  • ba1e73f8notes: a sent edit is done once the server's version is not older, so a second writer's text shows in the first tab; gate: two writers both waysmre
  • c69ef9ebsync components.hybriel 134b4e3: MdEditor builds an editor put into the page at once, redraws a surface put in anew (F5, hybriel#211)mre
  • 2eb783f5sync components 9a: shared Icon (icons/icons.hl), md-editor toolbar icons + single focus ring (components f4-icons ba96735)mre
  • 4dd46dadsync-components: copy icons/icons.hl + README (F4); testsmre
  • c92e4a0ftests/e2e-outside.mjs: real-Chrome E2E, a note pushed from another device while open, then typingmre
  • 0516b4ccmd-editor.hl: verbatim copy of components f3-mdvalue (an older text handed back is kept)mre
  • 38cc11ecmd-editor.hl: verbatim copy of components f3-mdvalue (an outside value change is shown by the editor)mre