From f11b07b647319ca93acdf1a91f50aa21f64e581b Mon Sep 17 00:00:00 2001 From: Thomas Taylor Date: Thu, 5 Mar 2026 13:04:39 +0000 Subject: [PATCH 1/2] Fix linter errors --- lib/api.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/api.js b/lib/api.js index 345fcf0..e029c97 100644 --- a/lib/api.js +++ b/lib/api.js @@ -81,7 +81,7 @@ class API { // cache state of plugins, as these will be wiped const plugins = (await new Project({ cwd }).getInstallTargets()) .map(p => p.isLocalSource ? p.sourcePath : `${p.name}@${p.requestedVersion}`) - + await this.installFramework({ version, repository, cwd, logger }) // restore plugins await this.installPlugins({ plugins, cwd, logger }) @@ -93,11 +93,11 @@ class API { * @returns {string} */ getCurrentFrameworkVersion ({ - cwd = process.cwd(), + cwd = process.cwd() } = {}) { return new Project({ cwd }).version } - + /** * @param {Object} options * @param {Object} [options.repository=ADAPT_FRAMEWORK] The github repository url From 3a9c2b2ed95faeb1bed645ec49ee7485fd91629f Mon Sep 17 00:00:00 2001 From: Thomas Taylor Date: Thu, 5 Mar 2026 13:05:04 +0000 Subject: [PATCH 2/2] Allow versionLimit to be passed to getLatestFrameworkVersion --- lib/api.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/api.js b/lib/api.js index e029c97..f5c6ca6 100644 --- a/lib/api.js +++ b/lib/api.js @@ -100,13 +100,15 @@ class API { /** * @param {Object} options + * @param {string} [options.versionLimit] Semver range to constrain the version lookup * @param {Object} [options.repository=ADAPT_FRAMEWORK] The github repository url * @returns {string} */ async getLatestFrameworkVersion ({ + versionLimit, repository = ADAPT_FRAMEWORK } = {}) { - return getLatestVersion({ repository }) + return getLatestVersion({ versionLimit, repository }) } /**