fix: support legacy and beta prerelease version formats
This commit is contained in:
@@ -22,7 +22,12 @@ type PackageJson = {
|
||||
};
|
||||
|
||||
function normalizePluginSyncVersion(version: string): string {
|
||||
return version.replace(/[-+].*$/, "");
|
||||
const normalized = version.trim().replace(/^v/, "");
|
||||
const base = /^([0-9]+\.[0-9]+\.[0-9]+)/.exec(normalized)?.[1];
|
||||
if (base) {
|
||||
return base;
|
||||
}
|
||||
return normalized.replace(/[-+].*$/, "");
|
||||
}
|
||||
|
||||
function runPackDry(): PackResult[] {
|
||||
|
||||
Reference in New Issue
Block a user