20638 Commits

Author SHA1 Message Date
ozan 4a9469cf65 feat: CLI install banner on dashboard + landing page in source
- Logged in: dashboard with dismissible CLI install banner (OS-detected command, copy button)
- Logged out: landing page with contact form
- Banner stored in localStorage, dismiss persists
- No more EFS template override needed
2026-05-22 07:07:05 +01:00
ozan 4e9c481545 docs: testing strategy handoff from ariki-game — 3-layer test pattern for agents
Autonomous agents must run tests before pushing. Pattern:
Layer 1 (unit): make test — pure logic, <1s
Layer 2 (integration): make test-sqlite — real DB, real handlers
Layer 3 (E2E): npx playwright test — browser tests

tinqs-git already has upstream Gitea test infra (better than ariki-game).
Gap: agents don't run them. This handoff fixes that.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-05-22 06:49:52 +01:00
ozan 579c45cabb brand: replace Gitea favicon with tinqs 't' icon, add tinqs wordmark logo 2026-05-22 05:10:54 +00:00
ozan a81a450e7e feat: monorepo consolidation — merge CLI, bot, admin, team-tool, website, docs, runner, proxy
Merged into tinqs/studio:
- cmd/tinqs-cli/    — tinqs-cli (Go binary, from bot/cli)
- cmd/tea/          — Gitea CLI tool (from tinqs/cli-tea)
- services/bot/     — Bot service (from tinqs-ltd/bot on git.arikigame.com)
- services/admin/   — Admin panel (from tinqs/admin)
- services/team-tool/ — Team Tool (from tinqs/team-tool)
- services/proxy/   — tinqs-proxy (from bot/proxy)
- web/landing/      — tinqs.com website (from tinqs/website)
- web/docs/         — Platform docs (from tinqs/docs)
- web/blog/         — Blog (placeholder)
- runner/           — Ephemeral CI runner (from tinqs/runner)

All source repos will be deleted after verification.
2026-05-22 04:55:50 +00:00
ozan 715f54e39d simplify: drop SWR cache, always upload fresh to S3
Always overwrites S3 on every preview request — no stale content.
Removed sync.Map cache and background goroutines.
Blob-by-SHA paths still skip upload if already exists (immutable).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-05-21 01:01:50 +01:00
ozan 01e862a238 test: add S3 image to announcement to verify images render in preview
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-05-21 00:50:04 +01:00
ozan 404a704d5e fix: Fullscreen button in header bar + full-width iframe
- Fullscreen button added to Preview/Source button group (not overlay)
- iframe breaks out of container: width:100vw with negative margins
- removed overlay expand icon — redundant with header button

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-05-21 00:37:31 +01:00
ozan 64e6b23492 docs: HTML preview feature announcement page
Test page for the S3-backed HTML preview. Demonstrates the feature
it describes — dark theme, Tinqs branding, inline CSS, no relative
image paths.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-05-21 00:32:35 +01:00
ozan 3b81d57414 fix: HTML preview iframe fills viewport + expand button
- height: calc(100vh - 220px) instead of fixed 600px — fills remaining
  viewport with no dead space at bottom
- expand button (screen-full icon) in top-right corner opens the S3
  presigned URL in a new tab for full-screen viewing
- security preserved: new tab opens S3 origin, not Gitea

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-05-20 23:50:47 +01:00
ozan a845b744b7 feat: HTML preview via S3 with SWR caching
HTML files now render in an iframe served from S3 (tinqs-git-preview
bucket) instead of Gitea's raw endpoint which forces text/plain.

SWR flow: first request uploads blob to S3 synchronously, subsequent
requests redirect to presigned S3 URL instantly. When the blob SHA
changes (new commit), the stale version is served immediately while
the new version uploads in the background.

Security: iframe uses sandbox="allow-scripts" only (no allow-same-origin).
S3 is a different origin from git.arikigame.com, so even if JS runs in
the iframe it cannot access Gitea session cookies or API tokens.

Config: [html_preview] section in app.ini, disabled by default.
Release pipeline auto-adds config on first deploy.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-05-20 23:33:40 +01:00
ozan 20f521cf16 fix: Preview/Source buttons only for .html/.htm, not other file types
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 15:04:45 +01:00
ozan 33703222f8 fix: visible Preview/Source buttons for HTML files, default to preview
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 15:02:20 +01:00
ozan 87848482a1 fix: clear template data for HTML files to ensure iframe renders
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 10:06:02 +01:00
ozan 99271119e8 fix: force-clear template data for HTML files to show iframe
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 09:58:06 +01:00
ozan 103092113e debug: log template data after HTML file handler
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 09:51:24 +01:00
ozan ce1e45fc1e debug: log when HTML handler serves a file
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 09:43:58 +01:00
ozan 9a53d1f4ed docs: add Deployment section (Lightsail, systemd, deploy commands) 2026-05-20 09:20:21 +01:00
ozan 0417c161b3 fix: navbar version badge also shows for admin users
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 09:10:52 +01:00
ozan 2280f9b04e branding: show tinqs-git + version in navbar and footer
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 08:59:54 +01:00
ozan e7110bc8ba fix: move HTML handler before markup — .html files were caught by markup renderer
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 08:44:10 +01:00
ozan adacd11e75 fix: use tinqs-cli-releases bucket (act-runner has PutObject there)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 08:10:35 +01:00
ozan 678fffb8aa ci: S3 pipeline — build uploads to s3://tinqs-builds, release downloads by version
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 08:07:51 +01:00
ozan 221b7bc587 ci: local deploy — no SSH, runner is on same Lightsail instance
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 07:33:31 +01:00
ozan 7f078f5734 ci: add release.yml — on-demand deploy via workflow_dispatch
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 07:26:00 +01:00
ozan 450e599c42 ci: remove upload-artifact@v4 (not supported on Gitea Actions)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 07:21:48 +01:00
ozan 3b31171c74 ci: simplify — just build, skip tests (Redis/globallock issues on runner)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 07:13:13 +01:00
ozan a782829b5f chore: update MEMORY — no separate deploy, git.arikigame.com stays
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 06:59:35 +01:00
ozan 6ce360aed4 chore: remove deploy.yml — no separate deploy, use git.arikigame.com
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 06:57:23 +01:00
ozan a3c5187565 fix: use -tags flag instead of TAGS env var for go test
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 06:49:20 +01:00
ozan e4a93f9dcc fix: skip Redis queue tests in CI (no Redis on runner)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 06:34:15 +01:00
ozan 84733256ae fix: use runs-on host — ubuntu-latest runners are offline
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 06:25:39 +01:00
ozan 22e313506e chore: update MEMORY — HTML preview single-file + diff views
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 06:22:32 +01:00
ozan 3b91fcbaf4 feat: HTML preview in PR/diff views — before/after iframes side-by-side
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 06:20:15 +01:00
ozan a4314afc01 feat: HTML file preview — render .html as pages, not source (Phase 1.1)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 06:06:29 +01:00
ozan 0f3c29fe28 chore: unignore .cursor/ — our agent infrastructure
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 05:31:12 +01:00
ozan f96fdbdf51 chore: agent infra — SOUL, MEMORY, AGENTS, CI, EPIC, README
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-20 05:30:16 +01:00
Lunny Xiao afdbd9b7c5 change log for 1.26.1 (#37357)
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2026-04-24 12:40:36 -07:00
silverwind 64d12024d6 Stabilize e2e logout propagation test (#37408)
Backport of #37403 to `release/v1.26`.

The `events › logout propagation` e2e test was racing the SSE connection
setup: if page2's SharedWorker had not finished registering its
messenger by the time page1 triggered logout, the event was silently
dropped and page2 stayed on the authenticated page.

Wait 500ms after verifying page2 is signed in, before triggering the
logout from page1, so the SharedWorker has time to register. Comment
points at a cleaner future fix (expose a ready attribute on the page)
that will also work for the planned WebSocket SharedWorker.

---
This PR was written with the help of Claude Opus 4.7

Co-authored-by: Claude (Opus 4.7) <noreply@anthropic.com>
2026-04-25 00:20:09 +08:00
Giteabot 6cc1ee9424 fix: dump with default zip type produces uncompressed zip (#37401) (#37402)
Backport #37401

Fix #37393

Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: wxiaoguang <2114189+wxiaoguang@users.noreply.github.com>
2026-04-24 17:45:10 +08:00
Giteabot 5d7768f34c Fix repo init README EOL (#37388) (#37399)
Backport #37388 by @wxiaoguang

Fix #27120

By the way, refactor ReserveLineBreakForTextarea to NormalizeStringEOL

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2026-04-23 23:33:25 +00:00
Giteabot 55a6cfe79b Fix org team assignee/reviewer lookups for team member permissions (#37365) (#37391)
Backport #37365 by @pisarz77

Fix team members missing from assignee list when `team_unit.access_mode`
is 0 but the doer is owner.

Fix  #34871

1. Use `GetTeamUserIDsWithAccessToAnyRepoUnit` for repo assignee list
2. Load assignee list for project issues directly
3. Use `GetTeamUserIDsWithAccessToAnyRepoUnit` for repo reviewer list

Signed-off-by: Jakub Pisarczyk <pisarz77@gmail.com>
Signed-off-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: pisarz77 <pisarz77@gmail.com>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: Claude (Opus 4.7) <noreply@anthropic.com>
2026-04-23 21:15:53 +02:00
Giteabot 1f643072c1 fix: commit status reporting (#37372) (#37386)
Backport #37372 by @bircni

Fixes the issue that status report always shows waiting to run, when
already running

https://github.com/go-gitea/gitea/issues/36906#issuecomment-4294545813

Co-authored-by: Nicolas <bircni@icloud.com>
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: Claude (Opus 4.7) <noreply@anthropic.com>
2026-04-23 16:43:32 +02:00
Giteabot 0280455356 Fix button layout shift when collapsing file tree in editor (#37363) (#37375)
Backport #37363 by @bytedream

---
old:


https://github.com/user-attachments/assets/136a9ce8-f229-4583-bf19-75258d085513

new:


https://github.com/user-attachments/assets/21b7c885-00f4-4295-9191-07b66ca58b64

Signed-off-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: bytedream <me@bytedream.dev>
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: Claude (Opus 4.7) <noreply@anthropic.com>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2026-04-22 21:52:48 +02:00
Giteabot a8e465e893 Add URL to Learn more about blocking a user. (#37355) (#37367)
Backport #37355 by @PineBale

Closes #29992

<img width="1308" height="828" alt="1"
src="https://github.com/user-attachments/assets/552c2e0f-8da6-4f71-8660-8e3f5a78ace5"
/>

Co-authored-by: PineBale <272794187+PineBale@users.noreply.github.com>
2026-04-22 18:38:05 +00:00
Giteabot fc9dfe0e56 fix: use TriggerEvent instead of Event in workflow runs API response for scheduled runs (#37288) (#37360)
Backport #37288 by @KalashThakare

## Summary

Fixes #37252

The `/api/v1/repos/{owner}/{repo}/actions/runs` endpoint was returning
`event: "push"` for workflow runs triggered by `schedule:` (cron),
instead
of `event: "schedule"`.

## Root Cause

`ActionRun` has two separate fields:
- `Event` — the workflow registration event (e.g. `push`, set when the
workflow file was first pushed)
- `TriggerEvent` — the actual event that triggered the run (e.g.
`schedule`)

`ToActionWorkflowRun` in `services/convert/action.go` was serializing
`run.Event` into the API response instead of `run.TriggerEvent`, causing
scheduled runs to be indistinguishable from push events via the API.

This was already asymmetric — the tasks/jobs API correctly used
`TriggerEvent`.

## Fix

Changed `ToActionWorkflowRun` to use `run.TriggerEvent` for the `event`
field in the API response, consistent with how the jobs API works.

## Before

`event: "push"` returned for all scheduled runs:

<img width="1112" height="191" alt="Screenshot 2026-04-19 115642"
src="https://github.com/user-attachments/assets/c0a169f5-bbd9-4f5d-9474-e4c3795110e4"
/>

## After

`event: "schedule"` correctly returned for scheduled runs:

<img width="890" height="166" alt="Screenshot 2026-04-19 121723"
src="https://github.com/user-attachments/assets/860e99ac-0935-4a43-86a1-7b60f8113480"
/>


## Testing

- Added unit test `TestToActionWorkflowRun_UsesTriggerEvent` in
  `services/convert/action_test.go` that explicitly verifies the API
  returns `TriggerEvent` and not `Event` for a scheduled run.
- Manually verified via the API against a live Gitea instance with a
  `cron: "* * * * *"` workflow.

Co-authored-by: Kalash Thakare ☯︎ <kalashthakare898@gmail.com>
Co-authored-by: Nicolas <bircni@icloud.com>
2026-04-22 18:39:10 +02:00
Giteabot 0916039c2a Add event.schedule context for schedule actions task (#37320) (#37348)
Backport #37320 by @lunny

Fix #35452

Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: Claude (Opus 4.7) <noreply@anthropic.com>
2026-04-21 21:45:12 +00:00
Giteabot 291f6cbd3a Fix an issue where changing an organization’s visibility caused problems when users had forked its repositories. (#37324) (#37344)
Backport #37324 by @lunny

A quick fix #37317

---

The current behavior for forks when an organization or repository is
changed to private differs from GitHub.

On GitHub, when a parent repository becomes private, the fork
relationship is removed, which keeps the behavior simple and avoids
visibility conflicts.

I think we need a similar solution to handle cases where the parent
repository becomes private while a fork remains public and the fork
relationship is still preserved.

Signed-off-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2026-04-21 19:22:35 +00:00
Giteabot f536bcd508 Use modern "git update-index --cacheinfo" syntax to support more file names (#37338) (#37343)
Backport #37338 by @wxiaoguang

Modern syntax was added in git 2.0

And add more tests

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2026-04-21 18:41:40 +00:00
Giteabot fc4296a21a Fix URL related escaping for oauth2 (#37334) (#37340)
Backport #37334 by wxiaoguang

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2026-04-21 17:11:19 +00:00
Giteabot 657ea10cf1 When the requested arch rpm is missing fall back to noarch (#37236) (#37339)
Backport #37236 by chethenry

This fixes: https://github.com/go-gitea/gitea/issues/37235

It uses the same changeset alpine packages got in:
https://github.com/go-gitea/gitea/issues/26691

Co-authored-by: chethenry <henry@visionlink.org>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2026-04-21 16:27:01 +00:00