mirror of
https://github.com/github/awesome-copilot.git
synced 2026-06-22 15:37:44 +00:00
chore: publish from staged
This commit is contained in:
+18
-7
@@ -10,9 +10,10 @@ import {
|
||||
HOOKS_DIR,
|
||||
INSTRUCTIONS_DIR,
|
||||
PLUGINS_DIR,
|
||||
repoBaseUrl,
|
||||
publishedArtifactBaseUrl,
|
||||
ROOT_FOLDER,
|
||||
SKILLS_DIR,
|
||||
sourceContentBaseUrl,
|
||||
TEMPLATES,
|
||||
vscodeInsidersInstallImage,
|
||||
vscodeInstallImage,
|
||||
@@ -268,14 +269,16 @@ function formatTableCell(text) {
|
||||
return s.trim();
|
||||
}
|
||||
|
||||
function makeBadges(link, type) {
|
||||
function makeBadges(link, type, linkIntent = "source") {
|
||||
const aka = AKA_INSTALL_URLS[type] || AKA_INSTALL_URLS.instructions;
|
||||
const rawBaseUrl =
|
||||
linkIntent === "published" ? publishedArtifactBaseUrl : sourceContentBaseUrl;
|
||||
|
||||
const vscodeUrl = `${aka}?url=${encodeURIComponent(
|
||||
`vscode:chat-${type}/install?url=${repoBaseUrl}/${link}`
|
||||
`vscode:chat-${type}/install?url=${rawBaseUrl}/${link}`
|
||||
)}`;
|
||||
const insidersUrl = `${aka}?url=${encodeURIComponent(
|
||||
`vscode-insiders:chat-${type}/install?url=${repoBaseUrl}/${link}`
|
||||
`vscode-insiders:chat-${type}/install?url=${rawBaseUrl}/${link}`
|
||||
)}`;
|
||||
|
||||
return `[](${vscodeUrl})<br />[](${insidersUrl})`;
|
||||
@@ -325,7 +328,7 @@ function generateInstructionsSection(instructionsDir) {
|
||||
const customDescription = extractDescription(filePath);
|
||||
|
||||
// Create badges for installation links
|
||||
const badges = makeBadges(link, "instructions");
|
||||
const badges = makeBadges(link, "instructions", "source");
|
||||
|
||||
if (customDescription && customDescription !== "null") {
|
||||
// Use the description from frontmatter, table-safe
|
||||
@@ -689,7 +692,7 @@ function generateUnifiedModeSection(cfg) {
|
||||
for (const { file, filePath, title } of entries) {
|
||||
const link = encodeURI(`${linkPrefix}/${file}`);
|
||||
const description = extractDescription(filePath);
|
||||
const badges = makeBadges(link, badgeType);
|
||||
const badges = makeBadges(link, badgeType, "source");
|
||||
let mcpServerCell = "";
|
||||
if (includeMcpServers) {
|
||||
const servers = extractMcpServerConfigs(filePath);
|
||||
@@ -795,7 +798,15 @@ function generatePluginsSection(pluginsDir) {
|
||||
pluginsContent += `| [${displayName}](${link}) | ${description} | ${itemCount} items | ${keywords} |\n`;
|
||||
}
|
||||
|
||||
return `${TEMPLATES.pluginsSection}\n${TEMPLATES.pluginsUsage}\n\n${pluginsContent}`;
|
||||
const publishedManifestUrl = `${publishedArtifactBaseUrl}/.github/plugin/marketplace.json`;
|
||||
const sourceTreeUrl = "https://github.com/github/awesome-copilot/tree/HEAD/plugins";
|
||||
const pluginLinkGuidance = [
|
||||
"",
|
||||
`- Published marketplace manifest (tool-facing): \`${publishedManifestUrl}\``,
|
||||
`- Source plugin content (human-authored): \`${sourceTreeUrl}\``,
|
||||
].join("\n");
|
||||
|
||||
return `${TEMPLATES.pluginsSection}\n${TEMPLATES.pluginsUsage}${pluginLinkGuidance}\n\n${pluginsContent}`;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user