docs/env.md: every VICTORY_* switch, generated by cargo xtask env; warn on unknown ones #83
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/uiliannn--VItoriaBr!83
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-83"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@lcg007xd-c on GitHub · 2026-11-25 22:08 UTC · original
lcg007xd-c:docs/victory-env-registry→main· +505 −1 · 7 files · 2 commits · openWhat
The code reads 256
VICTORY_*environment switches. The README, the other docs andvictory.example.tomldescribe 54 of them (issue #1 points at the undocumented ones). There was no list, so nothing tells a user that a switch is spelled wrong or has been renamed. It just does nothing.cargo xtask envwritesdocs/env.md. It lists everyVICTORY_*name that appears as a whole string literal in the Rust source, the files that read it, and whether the hand-written docs describe it. The table doesn't try to describe each switch. It shows where to look, and which ones still need writing up.env_table_is_currentprints a warning naming the command that fixes it, and passes. WithVICTORY_STRICT_TESTS=1(the switch the shader test skips use) it fails.cargo xtask env --checkalways fails on a stale table.VICTORY_*variable that isn't in the table, for example:warning: VICTORY_RELAYS is set but is no known switch (docs/env.md): a typo?.Friction
A PR that adds a switch without rerunning
cargo xtask envonly gets a test warning. No one's PR goes red over it. Until the table is regenerated, the startup warning also names that new switch, and its wording ("a typo?") allows for that.Tests
env_table_is_current, plusonly_whole_literals_count:"VICTORY_X"counts, but a message that starts with the prefix doesn't.the_table_lists_the_log_filterandunknown_names_with_the_prefix_are_reportedin victory-core.git grepof quotedVICTORY_names: the two lists are identical. A CRLF checkout of the table still passes. With one row removed, the test warns by default and fails when strict.--target x86_64-pc-windows-msvc) pass locally.Not tested: the warning when running the real binary on Windows. It's one
eprintln!inlogging::init, which every binary calls.🤖 Generated with Claude Code
View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.