Skip to content

Commit

Permalink
[FIX] Remove semver validation from node version read from .nvmrc (#2052
Browse files Browse the repository at this point in the history
)

* [FIX] Remove semver validation from node version read from .nvmrc

Node version can be specified as an alias (such as `iojs`, `lts/hydrogen` etc), so validating it as semver may cause errors for some users.

* update CHANGELOG.md
  • Loading branch information
khamilowicz authored Sep 18, 2023
1 parent 8751a28 commit 7ddd630
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ This is the log of notable changes to EAS CLI and related packages.

### 🐛 Bug fixes

- Support node aliases in .nvmrc. ([#2052](https://github.com/expo/eas-cli/pull/2052) by [@khamilowicz](https://github.com/khamilowicz))

### 🧹 Chores

- Rollouts: more robust printing function. ([#2047](https://github.com/expo/eas-cli/pull/2047) by [@quinlanj](https://github.com/quinlanj))
Expand Down
4 changes: 0 additions & 4 deletions packages/eas-cli/src/utils/profiles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import {
} from '@expo/eas-json';
import fs from 'fs-extra';
import path from 'path';
import semver from 'semver';

import Log, { learnMore } from '../log';

Expand Down Expand Up @@ -83,9 +82,6 @@ async function getNodeVersionFromFileAsync(projectDir: string): Promise<string |
} catch {
return undefined;
}
if (!semver.valid(semver.coerce(nodeVersion))) {
throw new Error(`Invalid node version in .nvmrc: ${nodeVersion}`);
}
return nodeVersion;
}

Expand Down

0 comments on commit 7ddd630

Please sign in to comment.