Skip to content

Commit 18e302f

Browse files
committed
Fix the version checking of DEPS file.
1 parent 82a4f5c commit 18e302f

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "depsync",
3-
"version": "1.3.15",
3+
"version": "1.3.16",
44
"author": "Dom Chen",
55
"homepage": "https://github.com/domchen/depsync",
66
"description": "Automatically synchronize the dependencies of a project by the DEPS configuration file.",

src/Config.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,8 @@ function parse(configFileName, version, platform) {
159159
Utils.error("The DEPS config requires a higher version of depsync tool: " + configFileName);
160160
Utils.error("Requires version: " + config.version);
161161
Utils.error("Current version: " + version);
162-
Utils.error("Please update the depsync tool and try again.");
162+
Utils.error("To upgrade the depsync tool, run:");
163+
Utils.error(" `npm install -g depsync`");
163164
return null;
164165
}
165166
let files = filterByPlatform(data.files, platform);

src/Program.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,11 @@ function makePadding(paddingLength) {
6363

6464

6565
function run(args) {
66-
let version = process.versions.node;
67-
if (Utils.compareVersion(version, "14.14.0") < 0) {
68-
Utils.error("Node.js version must be greater than or equal to 14.14.0\n");
66+
let nodeVersion = process.versions.node;
67+
if (Utils.compareVersion(nodeVersion, "14.14.0") < 0) {
68+
Utils.error("The depsync tool requires Node.js version 14.14.0 or later. ");
69+
Utils.error("Current version: " + nodeVersion);
70+
Utils.error("Please visit https://nodejs.org to download the latest version.");
6971
process.exit(1);
7072
}
7173
let commandOptions = CommandLine.parse(args);

0 commit comments

Comments
 (0)