refactor!: rename Titano to Chronos and move CI and releases to Gitea (#6)
CI / Build and test (push) Successful in 8m14s
CI / Windows tests and installer (push) Skipped
CI / YAML check (push) Successful in 7s
Release / Build, test and publish (push) Successful in 13m19s
CI / PostgreSQL 16 integration (push) Successful in 4m49s
CI / PostgreSQL 17 integration (push) Successful in 5m28s
CI / Docker image (push) Successful in 53s
Release / Server image (push) Failing after 10s

The owner renamed the product and moved the repository to the self-hosted
Gitea (https://gitea.encke-hake.ts.net/BalboSoft/Chronos) for more control,
and asked for Actions and a first automatic release with the server package
and the Windows exe (docs/requests/2026-10-23-chronos-gitea.md).

- Chronos everywhere: a byte-exact rename of contents and paths, then a
  per-language review of the forms the old name's ending had dictated.
- Gitea instead of GitHub: the update check, licence, issue and support
  links read ChronosReleasesUrl; the update check takes the highest stable
  version, offers a pre-release build its final release and reports a
  repository it cannot see as a failed check. EULA, security policy and
  Gitea issue forms live at the repository root.
- Gitea Actions for the Linux act_runner (.gitea/workflows): CI, release,
  nightly image and performance gates in the .NET SDK container with git
  checkout and the system SQLite. The release cross-compiles the Windows
  programs, checks their icon, version and DPI manifest, packs installers
  and zips, publishes the Gitea release and pushes the server image
  (REGISTRY_TOKEN). Windows-only tests run in an opt-in job on a Windows
  runner (WINDOWS_RUNNER).
- New Chronos.Tools commands: zip, gitea-release, postgres-ci (replaces the
  docker-exec script, which Gitea's service containers do not allow; the
  throw-away server runs without durability) and pe-check.
- Timed tests take their budget from TestTiming (CHRONOS_TEST_TIME_FACTOR,
  3 on the shared runner; the weekly performance gates keep theirs).

BREAKING CHANGE: programs, settings, data folders, file types, environment
variables and the Docker image use the new name; nothing is migrated from
Titano, which never had a release.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Alberto Balbo <alberto.balbo.96@gmail.com>
This commit was merged in pull request #6.
This commit is contained in:
Alby96andClaude Opus 5.5 authored and Alby96 committed 2026-10-23 12:45:18 +02:00
1 parent c99842cc86
commit f2b58522b9
1801 files changed
+11804 -10676

No files matched your search

@@ -0,0 +1,250 @@
-- Chronos schema v1 (SQLite). Ids are UUID text, instants ISO-8601 UTC text ('…Z'), camera wall-clock times
-- ISO-8601 text without zone, JSON as text, booleans as 0/1. Mirrors postgres/0001_initial.sql.
CREATE TABLE archives (
id TEXT NOT NULL PRIMARY KEY,
name TEXT NOT NULL,
root_path TEXT NOT NULL,
folder_template TEXT NOT NULL,
file_template TEXT NOT NULL,
schema_version INTEGER NOT NULL DEFAULT 1,
created TEXT NOT NULL,
proxy_long_edge INTEGER NOT NULL DEFAULT 1920
);
CREATE TABLE users (
id TEXT NOT NULL PRIMARY KEY,
username TEXT NOT NULL,
username_key TEXT NOT NULL UNIQUE,
display_name TEXT,
password_hash TEXT NOT NULL,
role INTEGER NOT NULL,
permissions INTEGER NOT NULL,
quota_bytes INTEGER NOT NULL DEFAULT 0,
used_bytes INTEGER NOT NULL DEFAULT 0,
disabled INTEGER NOT NULL DEFAULT 0,
must_change_password INTEGER NOT NULL DEFAULT 0,
created TEXT NOT NULL,
last_login TEXT
);
CREATE TABLE sequences (
id TEXT NOT NULL PRIMARY KEY,
archive_id TEXT NOT NULL REFERENCES archives (id) ON DELETE CASCADE,
title TEXT,
title_key TEXT NOT NULL,
search_text TEXT NOT NULL,
folder TEXT NOT NULL,
camera_make TEXT,
camera_model TEXT,
camera_serial TEXT,
lens TEXT,
first_capture TEXT,
last_capture TEXT,
frame_count INTEGER NOT NULL DEFAULT 0,
median_interval REAL,
total_bytes INTEGER NOT NULL DEFAULT 0,
status INTEGER NOT NULL DEFAULT 0,
rendered_count INTEGER NOT NULL DEFAULT 0,
verified_at TEXT,
hero_frame_id TEXT,
rating INTEGER NOT NULL DEFAULT 0,
notes TEXT,
settings_json TEXT,
analysis_json TEXT,
origin INTEGER NOT NULL DEFAULT 0,
sync_state INTEGER NOT NULL DEFAULT 0,
settings_version INTEGER NOT NULL DEFAULT 0,
frames_version INTEGER NOT NULL DEFAULT 0,
owner_user_id TEXT,
warning_count INTEGER NOT NULL DEFAULT 0,
updated_at TEXT NOT NULL
);
CREATE INDEX ix_sequences_archive_capture ON sequences (archive_id, first_capture, id);
CREATE INDEX ix_sequences_capture ON sequences (first_capture, id);
CREATE INDEX ix_sequences_camera ON sequences (camera_model);
CREATE TABLE frames (
id TEXT NOT NULL PRIMARY KEY,
sequence_id TEXT NOT NULL REFERENCES sequences (id) ON DELETE CASCADE,
idx INTEGER NOT NULL,
relative_path TEXT NOT NULL,
file_name TEXT NOT NULL,
original_file_name TEXT,
size INTEGER NOT NULL DEFAULT 0,
sha256 TEXT,
captured_at TEXT,
utc_offset_minutes INTEGER,
timestamp_source INTEGER NOT NULL DEFAULT 0,
exposure_time REAL,
f_number REAL,
iso INTEGER,
focal_length REAL,
exposure_bias REAL,
white_balance INTEGER,
orientation INTEGER NOT NULL DEFAULT 1,
width INTEGER NOT NULL DEFAULT 0,
height INTEGER NOT NULL DEFAULT 0,
format INTEGER NOT NULL DEFAULT 0,
preview_offset INTEGER,
preview_length INTEGER,
mean_log_luminance REAL,
clip_low REAL,
clip_high REAL,
flags INTEGER NOT NULL DEFAULT 0
);
CREATE UNIQUE INDEX ux_frames_sequence_idx ON frames (sequence_id, idx);
CREATE INDEX ix_frames_sha256 ON frames (sha256);
CREATE INDEX ix_frames_captured_at ON frames (captured_at);
CREATE TABLE renders (
id TEXT NOT NULL PRIMARY KEY,
sequence_id TEXT NOT NULL REFERENCES sequences (id) ON DELETE CASCADE,
preset_name TEXT NOT NULL,
settings_json TEXT,
output_path TEXT NOT NULL,
codec TEXT,
width INTEGER NOT NULL DEFAULT 0,
height INTEGER NOT NULL DEFAULT 0,
fps REAL NOT NULL DEFAULT 0,
duration_seconds REAL NOT NULL DEFAULT 0,
bytes INTEGER NOT NULL DEFAULT 0,
created TEXT NOT NULL,
produced_by TEXT
);
CREATE INDEX ix_renders_sequence ON renders (sequence_id, created);
CREATE TABLE jobs (
id TEXT NOT NULL PRIMARY KEY,
kind INTEGER NOT NULL,
target_ids TEXT NOT NULL DEFAULT '',
target_label TEXT,
parameters_json TEXT,
state INTEGER NOT NULL,
priority INTEGER NOT NULL,
progress_done INTEGER NOT NULL DEFAULT 0,
progress_total INTEGER NOT NULL DEFAULT 0,
items_per_second REAL,
eta_seconds REAL,
checkpoint TEXT,
log_tail TEXT,
created_by TEXT,
node_id TEXT,
attempts INTEGER NOT NULL DEFAULT 0,
error TEXT,
created TEXT NOT NULL,
started TEXT,
finished TEXT
);
CREATE INDEX ix_jobs_queue ON jobs (state, priority DESC, created, id);
CREATE INDEX ix_jobs_state_created ON jobs (state, created, id);
CREATE INDEX ix_jobs_finished ON jobs (finished);
CREATE TABLE media_cards (
id TEXT NOT NULL PRIMARY KEY,
identity TEXT NOT NULL UNIQUE,
volume_serial INTEGER NOT NULL,
label TEXT,
capacity INTEGER NOT NULL DEFAULT 0,
nickname TEXT,
camera_make TEXT,
camera_model TEXT,
camera_serial TEXT,
profile_json TEXT,
auto_import INTEGER NOT NULL DEFAULT 0,
first_seen TEXT NOT NULL,
last_seen TEXT NOT NULL
);
CREATE TABLE import_history (
card_id TEXT NOT NULL REFERENCES media_cards (id) ON DELETE CASCADE,
path TEXT NOT NULL,
size INTEGER NOT NULL,
mtime TEXT NOT NULL,
sha256 TEXT,
frame_id TEXT REFERENCES frames (id) ON DELETE SET NULL,
job_id TEXT,
imported_at TEXT NOT NULL,
PRIMARY KEY (card_id, path, size, mtime)
);
CREATE INDEX ix_import_history_frame ON import_history (frame_id);
CREATE TABLE tokens (
token_hash TEXT NOT NULL PRIMARY KEY,
user_id TEXT NOT NULL REFERENCES users (id) ON DELETE CASCADE,
client_name TEXT,
created TEXT NOT NULL,
expires TEXT NOT NULL,
last_used TEXT NOT NULL,
revoked INTEGER NOT NULL DEFAULT 0
);
CREATE INDEX ix_tokens_user ON tokens (user_id);
CREATE INDEX ix_tokens_expires ON tokens (expires);
CREATE TABLE render_nodes (
id TEXT NOT NULL PRIMARY KEY,
user_id TEXT NOT NULL REFERENCES users (id) ON DELETE CASCADE,
client_name TEXT NOT NULL,
capabilities_json TEXT,
last_heartbeat TEXT NOT NULL,
state TEXT NOT NULL
);
CREATE INDEX ix_render_nodes_user ON render_nodes (user_id);
CREATE INDEX ix_render_nodes_heartbeat ON render_nodes (last_heartbeat);
CREATE TABLE settings (
scope TEXT NOT NULL,
scope_id TEXT NOT NULL DEFAULT '',
key TEXT NOT NULL,
value_json TEXT NOT NULL,
updated_at TEXT NOT NULL,
PRIMARY KEY (scope, scope_id, key)
);
CREATE TABLE tags (
id TEXT NOT NULL PRIMARY KEY,
name TEXT NOT NULL,
name_key TEXT NOT NULL UNIQUE
);
CREATE TABLE sequence_tags (
sequence_id TEXT NOT NULL REFERENCES sequences (id) ON DELETE CASCADE,
tag_id TEXT NOT NULL REFERENCES tags (id) ON DELETE CASCADE,
PRIMARY KEY (sequence_id, tag_id)
);
CREATE INDEX ix_sequence_tags_tag ON sequence_tags (tag_id);
CREATE TABLE audit_log (
id TEXT NOT NULL PRIMARY KEY,
at TEXT NOT NULL,
user_id TEXT,
username TEXT,
action TEXT NOT NULL,
target_kind TEXT,
target_id TEXT,
details TEXT,
remote_address TEXT
);
CREATE INDEX ix_audit_log_at ON audit_log (at, id);
CREATE INDEX ix_audit_log_user ON audit_log (user_id, at);
CREATE TABLE uploads (
id TEXT NOT NULL PRIMARY KEY,
user_id TEXT NOT NULL REFERENCES users (id) ON DELETE CASCADE,
sequence_id TEXT REFERENCES sequences (id) ON DELETE SET NULL,
file_name TEXT NOT NULL,
size INTEGER NOT NULL,
sha256 TEXT NOT NULL,
captured_at TEXT,
chunk_size INTEGER NOT NULL,
received BLOB NOT NULL,
received_count INTEGER NOT NULL DEFAULT 0,
state INTEGER NOT NULL,
frame_id TEXT,
created TEXT NOT NULL,
updated_at TEXT NOT NULL
);
CREATE INDEX ix_uploads_user ON uploads (user_id, created);
CREATE INDEX ix_uploads_state ON uploads (state, updated_at);
CREATE INDEX ix_uploads_sha256 ON uploads (sha256);
CREATE INDEX ix_uploads_sequence ON uploads (sequence_id);
@@ -0,0 +1,23 @@
-- Archive index state (BRIEF §7, §14.4). Mirrors postgres/0002_archive_index.sql.
-- Automatic grouping: a session key (upload session, card session) resolves to the sequence created for it.
CREATE TABLE sequence_sessions (
archive_id TEXT NOT NULL REFERENCES archives (id) ON DELETE CASCADE,
session_key TEXT NOT NULL,
sequence_id TEXT NOT NULL REFERENCES sequences (id) ON DELETE CASCADE,
PRIMARY KEY (archive_id, session_key)
);
CREATE INDEX ix_sequence_sessions_sequence ON sequence_sessions (sequence_id);
-- What the last scan saw in each sequence folder, so incremental scans skip unchanged folders by size and time.
-- Times are UTC ticks (100 ns), compared exactly with the file system's.
CREATE TABLE archive_folders (
archive_id TEXT NOT NULL REFERENCES archives (id) ON DELETE CASCADE,
folder TEXT NOT NULL,
sequence_id TEXT REFERENCES sequences (id) ON DELETE SET NULL,
sidecar_size INTEGER,
sidecar_ticks INTEGER,
photos_ticks INTEGER,
scanned_at TEXT NOT NULL,
PRIMARY KEY (archive_id, folder)
);
@@ -0,0 +1,9 @@
-- Chronos Server additions (SQLite): automatic grouping key of frame uploads, render-result uploads of render-node
-- jobs, and the sign-in log lookup. Mirrors postgres/0003_server_uploads.sql.
ALTER TABLE uploads ADD COLUMN session_key TEXT;
ALTER TABLE uploads ADD COLUMN job_id TEXT;
ALTER TABLE uploads ADD COLUMN render_json TEXT;
CREATE INDEX ix_uploads_job ON uploads (job_id);
CREATE INDEX ix_audit_log_action ON audit_log (action, at);
@@ -0,0 +1,38 @@
-- Client sync state (BRIEF §4.4, §14.5): one row per sequence of a server this client has listed, linked to the local
-- copy when there is one. Versions are the counters both sides agreed on at the last sync; conflict_remote is the
-- server's side (title, tags, rating, notes, settings) of an unresolved conflict as JSON. Mirrors postgres/0004_sync.sql.
CREATE TABLE sync_links (
server TEXT NOT NULL,
remote_id TEXT NOT NULL,
local_id TEXT REFERENCES sequences (id) ON DELETE SET NULL,
title TEXT NOT NULL,
frame_count INTEGER NOT NULL DEFAULT 0,
total_bytes INTEGER NOT NULL DEFAULT 0,
render_count INTEGER NOT NULL DEFAULT 0,
remote_status INTEGER NOT NULL DEFAULT 0,
remote_settings_version INTEGER NOT NULL DEFAULT 0,
remote_frames_version INTEGER NOT NULL DEFAULT 0,
remote_updated_at TEXT NOT NULL,
base_local_settings INTEGER,
base_remote_settings INTEGER,
diff_local_frames INTEGER,
diff_remote_frames INTEGER,
diff_local_renders INTEGER,
diff_remote_renders INTEGER,
missing_remote INTEGER NOT NULL DEFAULT 0,
missing_local INTEGER NOT NULL DEFAULT 0,
exports_to_get INTEGER NOT NULL DEFAULT 0,
exports_to_get_bytes INTEGER NOT NULL DEFAULT 0,
exports_to_send INTEGER NOT NULL DEFAULT 0,
exports_to_send_bytes INTEGER NOT NULL DEFAULT 0,
conflict_local_settings INTEGER,
conflict_remote_settings INTEGER,
conflict_remote TEXT,
proxies_cached INTEGER NOT NULL DEFAULT 0,
proxies_frames_version INTEGER,
error TEXT,
synced_at TEXT,
PRIMARY KEY (server, remote_id)
);
CREATE UNIQUE INDEX ix_sync_links_local ON sync_links (server, local_id);
@@ -0,0 +1,7 @@
-- Decode tiers (BRIEF §8.2): the size of each frame's largest embedded preview (before orientation, like width and
-- height), which caps the output of sequences whose frames decode only through it, and per sequence the number of
-- those preview-only frames for the Library chip. Mirrors postgres/0005_decode_tiers.sql.
ALTER TABLE frames ADD COLUMN preview_width INTEGER NOT NULL DEFAULT 0;
ALTER TABLE frames ADD COLUMN preview_height INTEGER NOT NULL DEFAULT 0;
ALTER TABLE sequences ADD COLUMN preview_only_count INTEGER NOT NULL DEFAULT 0;
@@ -0,0 +1,5 @@
-- Client sync state (BRIEF §2.3, §14.5): the server's update time a linked copy's originals were compared at, kept
-- while proxies the server asks for may be made on this PC; they change without the frame counters moving, so the
-- copy is compared again when the server's sequence changed since. Mirrors postgres/0006_sync_proxy_compare.sql.
ALTER TABLE sync_links ADD COLUMN diff_remote_updated_at TEXT;