Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/shared/src/markdownLinks.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ describe("inlineCodeFilePathCandidate", () => {
// regression: #13909 model ids in inline code do not become file chips
it.each([
["src\\main.ts", "src/main.ts"],
["allocator.cc:217", "allocator.cc:217"],
["origin/main", null],
["z-ai/glm-5.3", null],
["share/man/ls.1", "share/man/ls.1"],
Expand Down
3 changes: 2 additions & 1 deletion packages/shared/src/markdownLinks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ const GENERIC_HOSTNAME_TLDS = new Set([
"xyz",
"me",
"tv",
"cc",
"gg",
"chat",
"cloud",
Expand Down Expand Up @@ -159,6 +158,8 @@ const COUNTRY_HOSTNAME_TLDS = new Set([
"tr",
"sg",
"hk",
// C++ sources end in `.cc`, so `allocator.cc:217` names a file, not a host and port.
"cc",
]);

function looksLikeHostname(segment: string, hasPosition: boolean): boolean {
Expand Down
Loading