@gadmin2n/cli 0.0.90 → 0.0.91
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.circleci/config.yml +62 -0
- package/.github/ISSUE_TEMPLATE/Bug_report.yml +106 -0
- package/.github/ISSUE_TEMPLATE/Feature_request.yml +52 -0
- package/.github/ISSUE_TEMPLATE/Regression.yml +78 -0
- package/.github/ISSUE_TEMPLATE/config.yml +7 -0
- package/.github/PULL_REQUEST_TEMPLATE.md +41 -0
- package/package.json +2 -2
- package/test/lib/compiler/hooks/__snapshots__/tsconfig-paths.hook.spec.ts.snap +68 -0
- package/test/lib/compiler/hooks/fixtures/aliased-imports/src/bar.tsx +1 -0
- package/test/lib/compiler/hooks/fixtures/aliased-imports/src/baz.js +1 -0
- package/test/lib/compiler/hooks/fixtures/aliased-imports/src/qux.jsx +1 -0
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
version: 2
|
|
2
|
+
|
|
3
|
+
aliases:
|
|
4
|
+
- &restore-cache
|
|
5
|
+
restore_cache:
|
|
6
|
+
key: dependency-cache-{{ checksum "package.json" }}
|
|
7
|
+
- &install-deps
|
|
8
|
+
run:
|
|
9
|
+
name: Install dependencies
|
|
10
|
+
command: npm ci
|
|
11
|
+
- &build-packages
|
|
12
|
+
run:
|
|
13
|
+
name: Build
|
|
14
|
+
command: npm run build
|
|
15
|
+
- &run-unit-tests
|
|
16
|
+
run:
|
|
17
|
+
name: Test
|
|
18
|
+
command: npm run test
|
|
19
|
+
|
|
20
|
+
jobs:
|
|
21
|
+
build:
|
|
22
|
+
working_directory: ~/nest
|
|
23
|
+
docker:
|
|
24
|
+
- image: circleci/node:17
|
|
25
|
+
steps:
|
|
26
|
+
- checkout
|
|
27
|
+
- run:
|
|
28
|
+
name: Update NPM version
|
|
29
|
+
command: 'sudo npm install -g npm@latest'
|
|
30
|
+
- restore_cache:
|
|
31
|
+
key: dependency-cache-{{ checksum "package.json" }}
|
|
32
|
+
- run:
|
|
33
|
+
name: Install dependencies
|
|
34
|
+
command: npm ci
|
|
35
|
+
- save_cache:
|
|
36
|
+
key: dependency-cache-{{ checksum "package.json" }}
|
|
37
|
+
paths:
|
|
38
|
+
- ./node_modules
|
|
39
|
+
- run:
|
|
40
|
+
name: Build
|
|
41
|
+
command: npm run build
|
|
42
|
+
|
|
43
|
+
unit_tests:
|
|
44
|
+
working_directory: ~/nest
|
|
45
|
+
docker:
|
|
46
|
+
- image: circleci/node:17
|
|
47
|
+
steps:
|
|
48
|
+
- checkout
|
|
49
|
+
- *restore-cache
|
|
50
|
+
- *install-deps
|
|
51
|
+
- *build-packages
|
|
52
|
+
- *run-unit-tests
|
|
53
|
+
|
|
54
|
+
workflows:
|
|
55
|
+
version: 2
|
|
56
|
+
build-and-test:
|
|
57
|
+
jobs:
|
|
58
|
+
- build
|
|
59
|
+
- unit_tests:
|
|
60
|
+
requires:
|
|
61
|
+
- build
|
|
62
|
+
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
name: "\U0001F41B Bug Report"
|
|
2
|
+
description: "If something isn't working as expected \U0001F914"
|
|
3
|
+
labels: ["needs triage", "bug"]
|
|
4
|
+
body:
|
|
5
|
+
- type: markdown
|
|
6
|
+
attributes:
|
|
7
|
+
value: |
|
|
8
|
+
## :warning: We use GitHub Issues to track bug reports, feature requests and regressions
|
|
9
|
+
|
|
10
|
+
If you are not sure that your issue is a bug, you could:
|
|
11
|
+
|
|
12
|
+
- use our [Discord community](https://discord.gg/NestJS)
|
|
13
|
+
- use [StackOverflow using the tag `nestjs`](https://stackoverflow.com/questions/tagged/nestjs)
|
|
14
|
+
- If it's just a quick question you can ping [our Twitter](https://twitter.com/nestframework)
|
|
15
|
+
|
|
16
|
+
**NOTE:** You don't need to answer questions that you know that aren't relevant.
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
- type: checkboxes
|
|
21
|
+
attributes:
|
|
22
|
+
label: "Is there an existing issue for this?"
|
|
23
|
+
description: "Please search [here](./?q=is%3Aissue) to see if an issue already exists for the bug you encountered"
|
|
24
|
+
options:
|
|
25
|
+
- label: "I have searched the existing issues"
|
|
26
|
+
required: true
|
|
27
|
+
|
|
28
|
+
- type: textarea
|
|
29
|
+
validations:
|
|
30
|
+
required: true
|
|
31
|
+
attributes:
|
|
32
|
+
label: "Current behavior"
|
|
33
|
+
description: "How the issue manifests?"
|
|
34
|
+
|
|
35
|
+
- type: input
|
|
36
|
+
validations:
|
|
37
|
+
required: true
|
|
38
|
+
attributes:
|
|
39
|
+
label: "Minimum reproduction code"
|
|
40
|
+
description: "An URL to some git repository or gist that reproduces this issue. [Wtf is a minimum reproduction?](https://jmcdo29.github.io/wtf-is-a-minimum-reproduction)"
|
|
41
|
+
placeholder: "https://github.com/..."
|
|
42
|
+
|
|
43
|
+
- type: textarea
|
|
44
|
+
attributes:
|
|
45
|
+
label: "Steps to reproduce"
|
|
46
|
+
description: |
|
|
47
|
+
How the issue manifests?
|
|
48
|
+
You could leave this blank if you alread write this in your reproduction code/repo
|
|
49
|
+
placeholder: |
|
|
50
|
+
1. `npm i`
|
|
51
|
+
2. `npm start:dev`
|
|
52
|
+
3. See error...
|
|
53
|
+
|
|
54
|
+
- type: textarea
|
|
55
|
+
validations:
|
|
56
|
+
required: true
|
|
57
|
+
attributes:
|
|
58
|
+
label: "Expected behavior"
|
|
59
|
+
description: "A clear and concise description of what you expected to happend (or code)"
|
|
60
|
+
|
|
61
|
+
- type: markdown
|
|
62
|
+
attributes:
|
|
63
|
+
value: |
|
|
64
|
+
---
|
|
65
|
+
|
|
66
|
+
- type: input
|
|
67
|
+
validations:
|
|
68
|
+
required: true
|
|
69
|
+
attributes:
|
|
70
|
+
label: "Package version"
|
|
71
|
+
description: |
|
|
72
|
+
Which version of `@nestjs/cli` are you using?
|
|
73
|
+
**Tip**: Make sure that all of yours `@nestjs/*` dependencies are in sync!
|
|
74
|
+
placeholder: "8.1.3"
|
|
75
|
+
|
|
76
|
+
- type: input
|
|
77
|
+
attributes:
|
|
78
|
+
label: "NestJS version"
|
|
79
|
+
description: "Which version of `@nestjs/core` are you using?"
|
|
80
|
+
placeholder: "8.1.3"
|
|
81
|
+
|
|
82
|
+
- type: input
|
|
83
|
+
attributes:
|
|
84
|
+
label: "Node.js version"
|
|
85
|
+
description: "Which version of Node.js are you using?"
|
|
86
|
+
placeholder: "14.17.6"
|
|
87
|
+
|
|
88
|
+
- type: checkboxes
|
|
89
|
+
attributes:
|
|
90
|
+
label: "In which operating systems have you tested?"
|
|
91
|
+
options:
|
|
92
|
+
- label: macOS
|
|
93
|
+
- label: Windows
|
|
94
|
+
- label: Linux
|
|
95
|
+
|
|
96
|
+
- type: markdown
|
|
97
|
+
attributes:
|
|
98
|
+
value: |
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
- type: textarea
|
|
102
|
+
attributes:
|
|
103
|
+
label: "Other"
|
|
104
|
+
description: |
|
|
105
|
+
Anything else relevant? eg: Logs, OS version, IDE, package manager, etc.
|
|
106
|
+
**Tip:** You can attach images, recordings or log files by clicking this area to highlight it and then dragging files in
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
name: "\U0001F680 Feature Request"
|
|
2
|
+
description: "I have a suggestion \U0001F63B!"
|
|
3
|
+
labels: ["feature"]
|
|
4
|
+
body:
|
|
5
|
+
- type: markdown
|
|
6
|
+
attributes:
|
|
7
|
+
value: |
|
|
8
|
+
## :warning: We use GitHub Issues to track bug reports, feature requests and regressions
|
|
9
|
+
|
|
10
|
+
If you are not sure that your issue is a bug, you could:
|
|
11
|
+
|
|
12
|
+
- use our [Discord community](https://discord.gg/NestJS)
|
|
13
|
+
- use [StackOverflow using the tag `nestjs`](https://stackoverflow.com/questions/tagged/nestjs)
|
|
14
|
+
- If it's just a quick question you can ping [our Twitter](https://twitter.com/nestframework)
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
- type: checkboxes
|
|
19
|
+
attributes:
|
|
20
|
+
label: "Is there an existing issue that is already proposing this?"
|
|
21
|
+
description: "Please search [here](./?q=is%3Aissue) to see if an issue already exists for the feature you are requesting"
|
|
22
|
+
options:
|
|
23
|
+
- label: "I have searched the existing issues"
|
|
24
|
+
required: true
|
|
25
|
+
|
|
26
|
+
- type: textarea
|
|
27
|
+
validations:
|
|
28
|
+
required: true
|
|
29
|
+
attributes:
|
|
30
|
+
label: "Is your feature request related to a problem? Please describe it"
|
|
31
|
+
description: "A clear and concise description of what the problem is"
|
|
32
|
+
placeholder: |
|
|
33
|
+
I have an issue when ...
|
|
34
|
+
|
|
35
|
+
- type: textarea
|
|
36
|
+
validations:
|
|
37
|
+
required: true
|
|
38
|
+
attributes:
|
|
39
|
+
label: "Describe the solution you'd like"
|
|
40
|
+
description: "A clear and concise description of what you want to happen. Add any considered drawbacks"
|
|
41
|
+
|
|
42
|
+
- type: textarea
|
|
43
|
+
attributes:
|
|
44
|
+
label: "Teachability, documentation, adoption, migration strategy"
|
|
45
|
+
description: "If you can, explain how users will be able to use this and possibly write out a version the docs. Maybe a screenshot or design?"
|
|
46
|
+
|
|
47
|
+
- type: textarea
|
|
48
|
+
validations:
|
|
49
|
+
required: true
|
|
50
|
+
attributes:
|
|
51
|
+
label: "What is the motivation / use case for changing the behavior?"
|
|
52
|
+
description: "Describe the motivation or the concrete use case"
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
name: "\U0001F4A5 Regression"
|
|
2
|
+
description: "Report an unexpected behavior while upgrading your Nest application!"
|
|
3
|
+
labels: ["needs triage"]
|
|
4
|
+
body:
|
|
5
|
+
- type: markdown
|
|
6
|
+
attributes:
|
|
7
|
+
value: |
|
|
8
|
+
## :warning: We use GitHub Issues to track bug reports, feature requests and regressions
|
|
9
|
+
|
|
10
|
+
If you are not sure that your issue is a bug, you could:
|
|
11
|
+
|
|
12
|
+
- use our [Discord community](https://discord.gg/NestJS)
|
|
13
|
+
- use [StackOverflow using the tag `nestjs`](https://stackoverflow.com/questions/tagged/nestjs)
|
|
14
|
+
- If it's just a quick question you can ping [our Twitter](https://twitter.com/nestframework)
|
|
15
|
+
|
|
16
|
+
**NOTE:** You don't need to answer questions that you know that aren't relevant.
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
- type: checkboxes
|
|
21
|
+
attributes:
|
|
22
|
+
label: "Did you read the migration guide?"
|
|
23
|
+
description: "Check out the [migration guide here](https://docs.nestjs.com/migration-guide)!"
|
|
24
|
+
options:
|
|
25
|
+
- label: "I have read the whole migration guide"
|
|
26
|
+
required: false
|
|
27
|
+
|
|
28
|
+
- type: checkboxes
|
|
29
|
+
attributes:
|
|
30
|
+
label: "Is there an existing issue that is already proposing this?"
|
|
31
|
+
description: "Please search [here](./?q=is%3Aissue) to see if an issue already exists for the feature you are requesting"
|
|
32
|
+
options:
|
|
33
|
+
- label: "I have searched the existing issues"
|
|
34
|
+
required: true
|
|
35
|
+
|
|
36
|
+
- type: input
|
|
37
|
+
attributes:
|
|
38
|
+
label: "Potential Commit/PR that introduced the regression"
|
|
39
|
+
description: "If you have time to investigate, what PR/date/version introduced this issue"
|
|
40
|
+
placeholder: "PR #123 or commit 5b3c4a4"
|
|
41
|
+
|
|
42
|
+
- type: input
|
|
43
|
+
attributes:
|
|
44
|
+
label: "Versions"
|
|
45
|
+
description: "From which version of `@nestjs/cli` to which version you are upgrading"
|
|
46
|
+
placeholder: "8.1.0 -> 8.1.3"
|
|
47
|
+
|
|
48
|
+
- type: textarea
|
|
49
|
+
validations:
|
|
50
|
+
required: true
|
|
51
|
+
attributes:
|
|
52
|
+
label: "Describe the regression"
|
|
53
|
+
description: "A clear and concise description of what the regression is"
|
|
54
|
+
|
|
55
|
+
- type: textarea
|
|
56
|
+
attributes:
|
|
57
|
+
label: "Minimum reproduction code"
|
|
58
|
+
description: |
|
|
59
|
+
Please share a git repo, a gist, or step-by-step instructions. [Wtf is a minimum reproduction?](https://jmcdo29.github.io/wtf-is-a-minimum-reproduction)
|
|
60
|
+
**Tip:** If you leave a minimum repository, we will understand your issue faster!
|
|
61
|
+
value: |
|
|
62
|
+
```ts
|
|
63
|
+
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
- type: textarea
|
|
67
|
+
validations:
|
|
68
|
+
required: true
|
|
69
|
+
attributes:
|
|
70
|
+
label: "Expected behavior"
|
|
71
|
+
description: "A clear and concise description of what you expected to happend (or code)"
|
|
72
|
+
|
|
73
|
+
- type: textarea
|
|
74
|
+
attributes:
|
|
75
|
+
label: "Other"
|
|
76
|
+
description: |
|
|
77
|
+
Anything else relevant? eg: Logs, OS version, IDE, package manager, etc.
|
|
78
|
+
**Tip:** You can attach images, recordings or log files by clicking this area to highlight it and then dragging files in
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
## To encourage contributors to use issue templates, we don't allow blank issues
|
|
2
|
+
blank_issues_enabled: false
|
|
3
|
+
|
|
4
|
+
contact_links:
|
|
5
|
+
- name: "\u2753 Discord Community of NestJS"
|
|
6
|
+
url: "https://discord.gg/NestJS"
|
|
7
|
+
about: "Please ask support questions or discuss suggestions/enhancements here."
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
## PR Checklist
|
|
2
|
+
Please check if your PR fulfills the following requirements:
|
|
3
|
+
|
|
4
|
+
- [ ] The commit message follows our guidelines: https://github.com/nestjs/nest/blob/master/CONTRIBUTING.md
|
|
5
|
+
- [ ] Tests for the changes have been added (for bug fixes / features)
|
|
6
|
+
- [ ] Docs have been added / updated (for bug fixes / features)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
## PR Type
|
|
10
|
+
What kind of change does this PR introduce?
|
|
11
|
+
|
|
12
|
+
<!-- Please check the one that applies to this PR using "x". -->
|
|
13
|
+
```
|
|
14
|
+
[ ] Bugfix
|
|
15
|
+
[ ] Feature
|
|
16
|
+
[ ] Code style update (formatting, local variables)
|
|
17
|
+
[ ] Refactoring (no functional changes, no api changes)
|
|
18
|
+
[ ] Build related changes
|
|
19
|
+
[ ] CI related changes
|
|
20
|
+
[ ] Other... Please describe:
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
## What is the current behavior?
|
|
24
|
+
<!-- Please describe the current behavior that you are modifying, or link to a relevant issue. -->
|
|
25
|
+
|
|
26
|
+
Issue Number: N/A
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
## What is the new behavior?
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
## Does this PR introduce a breaking change?
|
|
33
|
+
```
|
|
34
|
+
[ ] Yes
|
|
35
|
+
[ ] No
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
<!-- If this PR contains a breaking change, please describe the impact and migration path for existing applications below. -->
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
## Other information
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gadmin2n/cli",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.91",
|
|
4
4
|
"description": "Gadmin - modern, fast, powerful node.js web framework (@cli)",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"@angular-devkit/core": "13.3.2",
|
|
48
48
|
"@angular-devkit/schematics": "13.3.2",
|
|
49
49
|
"@angular-devkit/schematics-cli": "13.3.2",
|
|
50
|
-
"@gadmin2n/schematics": "^0.0.
|
|
50
|
+
"@gadmin2n/schematics": "^0.0.72",
|
|
51
51
|
"abc": "^0.6.1",
|
|
52
52
|
"chalk": "3.0.0",
|
|
53
53
|
"chokidar": "3.5.3",
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
+
|
|
3
|
+
exports[`tsconfig paths hooks should remove unused imports 1`] = `
|
|
4
|
+
Map {
|
|
5
|
+
"dist/foo.js" => "\\"use strict\\";
|
|
6
|
+
Object.defineProperty(exports, \\"__esModule\\", { value: true });
|
|
7
|
+
exports.Foo = void 0;
|
|
8
|
+
class Foo {
|
|
9
|
+
}
|
|
10
|
+
exports.Foo = Foo;
|
|
11
|
+
",
|
|
12
|
+
"dist/bar.js" => "\\"use strict\\";
|
|
13
|
+
Object.defineProperty(exports, \\"__esModule\\", { value: true });
|
|
14
|
+
exports.Bar = void 0;
|
|
15
|
+
class Bar {
|
|
16
|
+
}
|
|
17
|
+
exports.Bar = Bar;
|
|
18
|
+
",
|
|
19
|
+
"dist/main.js" => "\\"use strict\\";
|
|
20
|
+
Object.defineProperty(exports, \\"__esModule\\", { value: true });
|
|
21
|
+
",
|
|
22
|
+
}
|
|
23
|
+
`;
|
|
24
|
+
|
|
25
|
+
exports[`tsconfig paths hooks should replace path of every import using a path alias by its relative path 1`] = `
|
|
26
|
+
Map {
|
|
27
|
+
"dist/foo.js" => "\\"use strict\\";
|
|
28
|
+
Object.defineProperty(exports, \\"__esModule\\", { value: true });
|
|
29
|
+
exports.Foo = void 0;
|
|
30
|
+
class Foo {
|
|
31
|
+
}
|
|
32
|
+
exports.Foo = Foo;
|
|
33
|
+
",
|
|
34
|
+
"dist/bar.jsx" => "\\"use strict\\";
|
|
35
|
+
Object.defineProperty(exports, \\"__esModule\\", { value: true });
|
|
36
|
+
exports.Bar = void 0;
|
|
37
|
+
class Bar {
|
|
38
|
+
}
|
|
39
|
+
exports.Bar = Bar;
|
|
40
|
+
",
|
|
41
|
+
"dist/baz.js" => "\\"use strict\\";
|
|
42
|
+
Object.defineProperty(exports, \\"__esModule\\", { value: true });
|
|
43
|
+
exports.Baz = void 0;
|
|
44
|
+
class Baz {
|
|
45
|
+
}
|
|
46
|
+
exports.Baz = Baz;
|
|
47
|
+
",
|
|
48
|
+
"dist/qux.jsx" => "\\"use strict\\";
|
|
49
|
+
Object.defineProperty(exports, \\"__esModule\\", { value: true });
|
|
50
|
+
exports.Qux = void 0;
|
|
51
|
+
class Qux {
|
|
52
|
+
}
|
|
53
|
+
exports.Qux = Qux;
|
|
54
|
+
",
|
|
55
|
+
"dist/main.js" => "\\"use strict\\";
|
|
56
|
+
Object.defineProperty(exports, \\"__esModule\\", { value: true });
|
|
57
|
+
const foo_1 = require(\\"./foo\\");
|
|
58
|
+
const bar_1 = require(\\"./bar\\");
|
|
59
|
+
const baz_1 = require(\\"./baz\\");
|
|
60
|
+
const qux_1 = require(\\"./qux\\");
|
|
61
|
+
// use the imports so they do not get eliminated
|
|
62
|
+
console.log(foo_1.Foo);
|
|
63
|
+
console.log(bar_1.Bar);
|
|
64
|
+
console.log(baz_1.Baz);
|
|
65
|
+
console.log(qux_1.Qux);
|
|
66
|
+
",
|
|
67
|
+
}
|
|
68
|
+
`;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export class Bar {}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export class Baz {}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export class Qux {}
|