Skip to content

chore(desktop): stop tracking Tauri's generated gen/schemas - #63

Merged
twoimo merged 1 commit into
mainfrom
chore/untrack-tauri-gen-schemas
Nov 23, 2026
Merged

twoimo merged 1 commit into
mainfrom
chore/untrack-tauri-gen-schemas

Conversation

@twoimo

@twoimo twoimo commented Nov 23, 2026 •

Copy link
Copy Markdown
Owner

Why

The goal is to leave twoimo/alden with no open PRs or issues, each one resolved on its merits. PR #59 left one owner call open: whether desktop/src-tauri/gen/schemas/*.json should stay tracked. This PR settles it from Tauri's own guidance. People working on the desktop app stop seeing build-generated JSON churn in git status, and a build on another OS cannot rewrite tracked files.

Evidence

  • Tauri's official app template ignores the directory. create-tauri-app templates/_base_/src-tauri/_gitignore contains /gen/schemas under "Generated by Tauri, will have schema files for capabilities auto-completion".
  • A Tauri maintainer (amrbashir) answered in Should I commit schemas? tauri-apps/tauri#9051: "these should be excluded and ignored in git, they will be generated on each build if needed".
  • Tauri's capabilities guide (https://v2.tauri.app/security/capabilities/) points a capability file's $schema at ../gen/schemas/desktop-schema.json so the IDE can autocomplete it. This repo has no capability file that names it (git grep gen/schemas is empty), so the change touches no capability.

Change

desktop/.gitignore gains src-tauri/gen/schemas/, and the four generated files are untracked (git rm --cached). No file content is lost, because the build writes the files again.

Verification

In a clean worktree of this branch, with the four files deleted from disk:

  • npm ci and npm run build in desktop/ pass.
  • OPENKAKAO_TAURI_SOURCE_CHECK=1 cargo check --manifest-path desktop/src-tauri/Cargo.toml --locked passes and recreates all four files. Each one is byte-identical to the copy previously tracked on main (cmp), and git status shows them as ignored.
  • OPENKAKAO_TAURI_SOURCE_CHECK=1 cargo test --manifest-path desktop/src-tauri/Cargo.toml --locked: 86 passed.
  • No build or install script under scripts/ or desktop/ reads gen/.

🤖 Generated with Claude Code

tauri_build::build() rewrites desktop/src-tauri/gen/schemas on every
desktop build, and create-tauri-app's template ignores /gen/schemas.
Nothing in the repo reads these files; they only feed editor
completion for capability files.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@twoimo

twoimo commented Nov 23, 2026

Copy link
Copy Markdown
Owner Author

Decision: merge.

Evidence: the PR body has the verification. A desktop source build on this branch recreated all four schema files byte-identical to the copies tracked on main, and they show as ignored. Desktop cargo test passed 86 tests. Tauri's template and a maintainer answer both say to ignore /gen/schemas. This is a trivial ignore-and-untrack change with no code path, so it got no second-model review. GitHub-hosted Actions are blocked by billing, so the zero-step check failures are infra state.

@twoimo
twoimo merged commit c5e67e6 into main Nov 23, 2026
4 checks passed
@twoimo
twoimo deleted the chore/untrack-tauri-gen-schemas branch November 23, 2026 04:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant