Support relative pathing for `ng generate` statements
- Ngôn ngữ chính
- TypeScript
- Star
- 27k
- Fork
- 11.8k
- Merge trung bình
- 14 giờ 23 phút
- Pull request đã merge (30 ngày)
- 162
Mô tả
### Bug Report or Feature Request (mark with an `x`)
```
- [ ] bug report -> please search issues before submitting
- [x] feature request
```
### Versions.
```@angular/cli: 1.0.4
node: 6.10.2
os: linux x64
@angular/common: 4.1.3
@angular/compiler: 4.1.3
@angular/core: 4.1.3
@angular/forms: 4.1.3
@angular/http: 4.1.3
@angular/platform-browser: 4.1.3
@angular/platform-browser-dynamic: 4.1.3
@angular/router: 4.1.3
@angular/cli: 1.0.4
@angular/compiler-cli: 4.1.3
```
### Repro steps.
From project root:
```
ng g component ./src/app/components/test
```
### The log given by the failure.
```
installing component
create src/app/src/app/components/test/test.component.scss
create src/app/src/app/components/test/test.component.html
create src/app/src/app/components/test/test.component.spec.ts
create src/app/src/app/components/test/test.component.ts
```
### Desired functionality.
Doesn't create src/app under the (already existing) src/app directory.
This is a minor change, but would then allow me to use autocomplete with the generator, even if the immediate fix is to just remove 'src/app' from the file location input before processing.
### Mention any other details that might be useful.
Hướng dẫn đóng góp
Hướng nghiên cứu
Tái hiện sự cố từ thư mục gốc của dự án bằng `ng g component ./src/app/components/test` và kiểm tra cách trình tạo Angular CLI phân giải đường dẫn tương đối đó. Công việc được xem là hoàn tất khi các tệp được tạo nằm trong thư mục `src/app` hiện có mà không tạo đường dẫn trùng lặp `src/app/src/app`.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- angular, typescript
- Lĩnh vực
- cli, tooling
- Loại issue
- Tính năng
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 38/100