Conversation
There was a problem hiding this comment.
Pull request overview
Restores the previously removed windows-rs “feature search” by adding a metadata-driven generator that produces a self-contained static search page under web/features, and wiring up CI to keep it regenerated and deploy it via GitHub Pages (addressing #4631).
Changes:
- Add
tool_featuresto generateweb/features/index.htmlfrom the bundled.winmdmetadata, including extra required features inferred from function/method signatures. - Add a GitHub Pages workflow to deploy the
web/folder (serving the page at/features). - Extend the
genworkflow matrix to include the newfeaturestool so generated output stays up to date.
Reviewed changes
Copilot reviewed 4 out of 5 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| crates/tools/features/src/main.rs | Implements the metadata scan and emits a dependency-free, inlined-index web/features/index.html. |
| crates/tools/features/Cargo.toml | Adds the new tool_features crate configuration and dependency on windows-metadata. |
| .github/workflows/web.yml | Deploys ./web to GitHub Pages on updates, enabling the /features endpoint. |
| .github/workflows/gen.yml | Adds features to the tool generation matrix so CI verifies the generated page is current. |
| if (own) features.push(own); | ||
| if (extras) for (const ei of extras) { const f = featureOf(DATA.namespaces[ei]); if (f) features.push(f); } | ||
| const cell = features.length | ||
| ? features.map(f => '<code class="feature">' + f + '</code>').join(' + ') |
There was a problem hiding this comment.
Can this be changed to render features enclosed in ASCII double quotes ("), concatenated by , instead of +? This would enable copy-pasting the output straight into Cargo.toml, just like the previous feature search did.
There was a problem hiding this comment.
Thanks, yes I was planning to fix that but I'm waiting on @riverar to decide if this is sufficient or he wants to shoot for something a little more elaborate. If not, I'll get this updated.
Fixes: #4631