Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(nest): fix invalid nestjs versions #16771

Merged
merged 1 commit into from
May 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
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
8 changes: 4 additions & 4 deletions packages/nest/migrations.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,15 @@
"version": "16.1.0-beta.0",
"packages": {
"@nestjs/common": {
"version": "^9.1.0",
"version": "^9.1.1",
"alwaysAddToPackageJson": false
},
"@nestjs/core": {
"version": "^9.1.0",
"version": "^9.1.1",
"alwaysAddToPackageJson": false
},
"@nestjs/platform-express": {
"version": "^9.1.0",
"version": "^9.1.1",
"alwaysAddToPackageJson": false
},
"@nestjs/schematics": {
Expand All @@ -67,7 +67,7 @@
"alwaysAddToPackageJson": false
},
"@nestjs/testing": {
"version": "^9.1.0",
"version": "^9.1.1",
"alwaysAddToPackageJson": false
}
}
Expand Down
8 changes: 6 additions & 2 deletions packages/nest/src/generators/init/init.spec.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
import type { Tree } from '@nx/devkit';
import * as devkit from '@nx/devkit';
import { createTreeWithEmptyWorkspace } from '@nx/devkit/testing';
import { nestJsVersion, nxVersion } from '../../utils/versions';
import {
nestJsSchematicsVersion,
nestJsVersion,
nxVersion,
} from '../../utils/versions';
import { initGenerator } from './init';

describe('init generator', () => {
Expand All @@ -26,7 +30,7 @@ describe('init generator', () => {
expect(packageJson.dependencies['tslib']).toBeDefined();
expect(packageJson.dependencies['@nx/nest']).toBeUndefined();
expect(packageJson.devDependencies['@nestjs/schematics']).toBe(
nestJsVersion
nestJsSchematicsVersion
);
expect(packageJson.devDependencies['@nestjs/testing']).toBe(nestJsVersion);
expect(packageJson.devDependencies['@nx/nest']).toBe(nxVersion);
Expand Down
3 changes: 2 additions & 1 deletion packages/nest/src/generators/init/lib/add-dependencies.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import type { GeneratorCallback, Tree } from '@nx/devkit';
import { addDependenciesToPackageJson } from '@nx/devkit';
import {
nestJsSchematicsVersion,
nestJsVersion,
nxVersion,
reflectMetadataVersion,
Expand All @@ -20,7 +21,7 @@ export function addDependencies(tree: Tree): GeneratorCallback {
tslib: tsLibVersion,
},
{
'@nestjs/schematics': nestJsVersion,
'@nestjs/schematics': nestJsSchematicsVersion,
'@nestjs/testing': nestJsVersion,
'@nx/nest': nxVersion,
}
Expand Down
3 changes: 2 additions & 1 deletion packages/nest/src/utils/versions.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
export const nxVersion = require('../../package.json').version;

export const nestJsVersion = '^9.1.0';
export const nestJsVersion = '^9.1.1';
export const nestJsSchematicsVersion = '^9.1.0';
export const rxjsVersion = '^7.8.0';
export const reflectMetadataVersion = '^0.1.13';
export const tsLibVersion = '^2.3.0';