Rebrand to KuentaGYM, and start a new profile in pounds and Spanish

The app is now KuentaGYM everywhere a user can see it, and a fresh profile no
longer starts on upstream's English/kg defaults. Both are this fork's decisions,
so both are pinned by tests rather than left to a find-and-replace.

Rename (1,270 references, 149 files)

- Visible surfaces: the Login/Home/mobile-onboarding wordmark, the Settings
  version line, the printed plan, the PWA title + manifest, and the 17 branded
  strings across all 14 locale packs.
- Infrastructure: repo links, the container images and the release endpoints now
  name git.dploy.lol/dsantillan/kuentagym; .gitea/workflows/docker-publish.yml
  publishes to this forge's registry instead of gitea.com.
- The Android/iOS application id stays ch.duartesantos.opengym on purpose:
  changing it would make the mobile app a different app that could never update
  an installed copy.

Three things the mechanical pass would have broken, fixed here

- The update check asked gitlab.com for upstream's releases and would have
  installed upstream's APK, putting the old name back on the phone. It now reads
  this fork's Gitea releases API (the assets shape differs), with the tests
  rewritten to the payload Gitea actually returns.
- Renaming the mobile state/pairing files (opengym-state.json,
  opengym-remote.json) would lose the on-device copy of a history whose WebView
  storage may have been evicted, and silently unpair the device. Both are read
  under their old names and written forward under the new ones.
- Renaming the exported plan-file marker (openGym_plan) rejected every plan
  shared before the rename as "not a plan file". Both markers are accepted.

Defaults: pounds and Spanish

- DEF.unit = 'lb', DEF.lang = 'es', plus every fallback that independently
  assumed en/kg (the <html lang> attribute, the Settings pickers, the Store, the
  MCP, the Coach payload).
- Server-generated push copy existed only in English and pt-BR, so a Spanish
  profile would have been notified in English; Spanish added.
- The demo seed states unit: 'kg' — its seeded numbers are kilograms, and
  inheriting the new default would have introduced an 82.4 lb lifter benching 60.
- The module-level language in i18n-core stays English: it is the only language
  whose strings need no pack, so `t()`, dates, numbers and lists agree before a
  pack loads. Starting there on 'es' formats a Spanish-shaped UI with English
  strings.

Also
- api/package.json's test glob missed push-messages.test.js and
  verify-error.test.js, which sat beside the modules they cover and never ran.
- README, docs/, website/ and the issue templates no longer describe upstream's
  GitLab/GitHub pipeline, Discord, sponsorship or public demo as if they were
  this fork's; upstream history and attribution are preserved (NOTICE.md).
This commit is contained in:
dsantillan committed 2026-09-21 14:29:54 -04:00
1 parent f91cde15a1
commit 87bfd6d4c4
152 files changed
+1784 -1604

No files matched your search

+10 -10
View File
@@ -83,13 +83,13 @@ function prTable(S, formula) {
/** list_routines — names + counts of each routine in the user's plan. */
export const listRoutines = {
name: 'list_routines',
description: 'List the workout routines saved in the user\'s openGym profile (the same list the Plan screen shows). Each routine is a named set of exercises with set/rep targets. Use this to discover the plan structure before diving into a specific routine or today\'s workout.',
description: 'List the workout routines saved in the user\'s KuentaGYM profile (the same list the Plan screen shows). Each routine is a named set of exercises with set/rep targets. Use this to discover the plan structure before diving into a specific routine or today\'s workout.',
schema: {},
handler: () => {
const S = getState()
if (!S) return noState()
return {
unit: S.unit || 'kg',
unit: S.unit || 'lb',
routines: (S.routines || []).map(r => ({
id: r.id,
name: r.name,
@@ -120,7 +120,7 @@ export const getRoutine = {
policy: policyFor(null, r, 'reps'),
policy_name: policyName(policyFor(null, r, 'reps')),
exclude_from_progression: r.excludeFromProgression === true,
unit: S.unit || 'kg',
unit: S.unit || 'lb',
exercises: (r.ex || []).map((cfg, i) => {
const ex = exerciseOf(cfg.id, S)
const mode = modeOf(cfg)
@@ -146,7 +146,7 @@ export const getRoutine = {
policy: policyFor(cfg, r, mode),
policy_override: cfg.prog || null,
superset_group: cfg.sg || null,
summary: exLine(cfg, S.unit || 'kg')
summary: exLine(cfg, S.unit || 'lb')
}
})
}
@@ -156,7 +156,7 @@ export const getRoutine = {
/** get_week_plan — what's scheduled each weekday + today. */
export const getWeekPlan = {
name: 'get_week_plan',
description: 'Show the user\'s weekly plan: which routine (if any) is assigned to each weekday, keyed by JS getDay() (Sunday=0, Monday=1, … Saturday=6 — the same convention the openGym state file uses). Also reports today\'s date and what routine applies today, accounting for one-off overrides the user may have set for a specific date (a "rest" override cancels the day).',
description: 'Show the user\'s weekly plan: which routine (if any) is assigned to each weekday, keyed by JS getDay() (Sunday=0, Monday=1, … Saturday=6 — the same convention the KuentaGYM state file uses). Also reports today\'s date and what routine applies today, accounting for one-off overrides the user may have set for a specific date (a "rest" override cancels the day).',
schema: {},
handler: () => {
const S = getState()
@@ -207,7 +207,7 @@ export const listWorkouts = {
return true
}).slice(0, lim)
return {
unit: S.unit || 'kg',
unit: S.unit || 'lb',
total_count: all.length,
returned_count: filtered.length,
workouts: filtered.map(w => ({
@@ -282,7 +282,7 @@ export const getWorkout = {
date: w.d,
routine_id: w.routineId || null,
routine_name: w.name || null,
unit: S.unit || 'kg',
unit: S.unit || 'lb',
bodyweight_at_workout: w.bw || null,
volume: workoutVolume(w),
sets_done: setsDone(w),
@@ -316,7 +316,7 @@ export const getBodyweight = {
}).sort((a, b) => (a.d || '').localeCompare(b.d || ''))
const latest = bw.length ? bw[bw.length - 1] : null
return {
unit: S.unit || 'kg',
unit: S.unit || 'lb',
goal,
count: bw.length,
latest: latest ? { date: latest.d, weight: latest.w, delta_vs_goal: goal != null ? Math.round((latest.w - goal) * 10) / 10 : null } : null,
@@ -463,7 +463,7 @@ export const previewSession = {
if (!r) return { date: iso, routine_id: null, routine_name: null, rest_day: true, note: 'no routine is scheduled for this date (rest day)', exercises: [] }
}
const unit = S.unit || 'kg'
const unit = S.unit || 'lb'
// The same builder the app starts a session with (sheets.jsx beginWorkout → session-start.js):
// prescription, step, progression-off targets, deload routines and warm-up ramps all come from
// there, so the preview cannot drift from what the screen shows.
@@ -571,7 +571,7 @@ export const TOOLS = [
function noState() {
return {
error: 'no synced state yet — sign in at least once from a device so the openGym api can save a state file for this profile',
error: 'no synced state yet — sign in at least once from a device so the KuentaGYM api can save a state file for this profile',
unit: 'kg'
}
}