Skip to content
Closed
Changes from 1 commit
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
9 changes: 9 additions & 0 deletions scripts/validate-plugins.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,15 @@ if (!validateMarketplace(marketplace)) {

// 2. Validate each plugin
for (const entry of marketplace.plugins ?? []) {
// The schema allows `source` to be a remote URL. Nothing here fetches it, so
// say so instead of resolving it as a path (which turns "https://x" into
// "<root>/https:/x" and reports a missing directory).
if (/^https?:\/\//.test(entry.source)) {
console.log(
`INFO: Plugin "${entry.name}": remote source "${entry.source}" is not validated locally`
);
continue;
}
const pluginDir = resolve(root, entry.source);
const pluginJsonPath = resolve(pluginDir, ".cursor-plugin/plugin.json");

Expand Down