Skip to content

Feature: Show LinuxFiles release notes on the Release notes page - #203

Merged
MemerGamer merged 1 commit into
mainfrom
linux/release-notes-markdown
Oct 21, 2026
Merged

MemerGamer merged 1 commit into
mainfrom
linux/release-notes-markdown

Conversation

@MemerGamer

Copy link
Copy Markdown
Owner

Resolved / Related Issues

What changes

On Linux, the Release notes page now shows the LinuxFiles GitHub release notes for the running version. Before, it pointed at the upstream Files blog (files.community/blog/posts/v0-1-0?minimal, which does not exist for LinuxFiles versions). On X11 that gave a blank WebView2, and on Wayland it opened the browser.

  • ReleaseNotesHelper (new) calls GET https://api.github.com/repos/MemerGamer/LinuxFiles/releases/tags/linux-v<Version> and uses the release body. The version is the informational version, i.e. <Version> in Files.App.csproj (0.1.0-alpha8 → linux-v0.1.0-alpha8). The request has a 10 s timeout, a LinuxFiles/<version> User-Agent, no authentication and a 1 MiB response cap. A successful result is cached for the session (one request per launch, since the startup check and the page share it). A failure is retried the next time the page opens.
  • The Markdown is rendered with the existing Markdig renderer (PreviewTextRenderer, already used for Markdown previews). No new dependency. The page uses the same "paragraph → TextBlock" approach as the preview because RichTextBlock draws nothing on Uno Skia. That loop moved into PreviewTextRenderer.AddParagraphTextBlocks so both callers share it.
  • Links: AddMarkdownBlocks takes an optional openLink callback. When the callback is set, only absolute http/https links become Hyperlinks, and they open through ILauncherService (xdg-open, the default browser). Without the callback, links stay inert text exactly as before, so file previews are unchanged.
  • Images are never loaded (only their alt text is shown), and HTML is disabled in the pipeline and shown as literal text, as before.
  • Fallback (offline, 404, rate limit, empty body): the existing "Release Notes" link button, which also opens the release page in the default browser like the Wayland fallback did. The fallback URL now points at https://github.com/MemerGamer/LinuxFiles/releases/tag/linux-v<Version> instead of the upstream blog. WebView2 is no longer used on Linux, because it has no native backend there (see docs/linux-port/wayland-previews.md). It is still realized on demand (x:Load="False" + FindName) on non-Linux paths, which keeps those compiling.
  • DummyUpdateService.CheckForReleaseNotesAsync uses the same fetch on Linux, so the Release notes command becomes executable when notes exist. I removed its no-op PropertyChanged override, which swallowed change notifications, so OpenReleaseNotesAction now sees the update. AppEnvironment is Dev on Linux, so this does not auto-open the page after an update.
  • Docs: wayland-previews.md describes the new behaviour; added a CHANGELOG "Unreleased" entry.

No new user-visible strings (it reuses the ReleaseNotes resource). Files touched are LF/UTF-8 as before (BOMs kept).

Steps used to test these changes

  1. Built as CI does (Release, -f net10.0-desktop -p:FilesWin32Compat=false, plus Files.Shared, Core.Storage, SourceGenerator, Platform.Linux, App.Controls, App.Storage): 0 errors. Files.App.CsWin32 was not built. The only new warnings are Uno0001 for RichTextBlock/Block.Margin (same as the existing text preview) and Uno0007 for ProgressRing, which LinuxHtmlPreview already uses.
  2. Ran the app on a private Xvfb display with scripts/linux/headless-run.sh (throwaway home, FILES_LAUNCH_DRYRUN=1). Typed ReleaseNotes in the address bar: the alpha8 release notes rendered with headings, bullet lists, bold, code blocks and coloured links.
  3. Clicked a link in the notes: the launcher logged xdg-open https://github.com/files-community/Files.
  4. Ran with an unreachable HTTPS proxy to simulate offline: the page showed the "Release Notes" link button and the launcher opened https://github.com/MemerGamer/LinuxFiles/releases/tag/linux-v0.1.0-alpha8.
  5. tests/Files.Platform.Tests builds. Its tests do not reference Files.App. Locally 39 permission/ownership tests fail because the container runs as root; they are unrelated to this diff, and CI runs them as a normal user.

Not verified / limitations

  • Not run on a native Wayland session or with a real browser (container X11/Xvfb only). The loading ProgressRing may be invisible on Uno without Lottie, as in the HTML preview.
  • I did not re-check the info-pane Markdown preview after moving the shared TextBlock loop. The change is a straight extraction.
  • There is no persistent cache: an offline launch shows the fallback. The bundled docs/linux-port/release-notes/<version>.md is not shipped with the app, so it is not used as an offline source.
  • Relative links and mailto: stay inert text. Pipe tables render as plain paragraphs (pipeline unchanged).
  • The footer "Sponsor us on GitHub" still points at the upstream sponsor page (unchanged, out of scope).
  • Local builds used the Ubuntu .NET 10.0.113 SDK with the Roslyn 5.9 compiler toolset injected from the command line (the container cannot reach the Microsoft SDK download host), with NuGetAudit=false because the CommunityToolkit-Labs Azure feed is blocked here. Nothing build-related is committed.

AI disclosure

Most of the code in this PR was written by AI agents (Claude Code) under the maintainer's direction. The maintainer reviews and decides on merging.


Generated by Claude Code

On Linux the page now fetches the GitHub release for the running version
(linux-v<Version>) and renders its Markdown with the existing Markdig
preview renderer. Links open in the default browser; images show only alt
text and HTML stays literal. When the fetch fails the page links to the
GitHub release page instead of the upstream Files blog.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FBkiuJoaDgZGawU94wvpCJ
@MemerGamer
MemerGamer merged commit 8af8015 into main Oct 21, 2026
3 checks passed
@MemerGamer
MemerGamer deleted the linux/release-notes-markdown branch October 21, 2026 07:58
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.

2 participants