Skip to content

feat(@schematics/angular): Allow generation of suffix-free files #16891

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

Closed
wants to merge 1 commit into from

Conversation

sacgrover
Copy link
Contributor

Allow generation of suffix-free file and symbol names.
Fix #16811

Allow generation of suffix-free file and symbol names.
Fix angular#16811
@sacgrover
Copy link
Contributor Author

@alan-agius4 / @clydin
Any advice on ci/circleci: build-bazel FAIL?
ci/circleci: flake-jail is getting passed on local but not on github.

@filipesilva filipesilva added the needs: discussion On the agenda for team meeting to determine next steps label Feb 11, 2020
@dgp1130
Copy link
Collaborator

dgp1130 commented Feb 13, 2020

@mgechev, can you give this a quick look? We're not sure exactly what you were expecting from the design perspective here. Is this what you had in mind?

@mgechev
Copy link
Member

mgechev commented Feb 13, 2020

We haven't discussed design yet. My suggestion would be to deprecate the type option (in v10) and replace it with a suffix one, which accepts an empty string. With @clydin we discussed few alternatives and this seems like the cleanest one.

If you see corner cases, we can draft a design document.

@sacgrover
Copy link
Contributor Author

@mgechev / @dgp1130 Should I close this PR?

@clydin
Copy link
Member

clydin commented Feb 17, 2020

Something that can be fixed for the current version is the type option on several of the schematics. When setting the type to an empty string the file names generated will contain an extra period (.). Fixing this would act as an enabler for the proposed name change to suffix in a later version.

@dgp1130
Copy link
Collaborator

dgp1130 commented Feb 20, 2020

Spoke with @mgechev and @jelbourn, they both agree Minko's design of converting type to suffix and accepting an empty string is the way to go. So I think we have consensus on the design side.

I think we can follow @clydin's suggestion to allow an empty string type to and go from there.

@sacgrover
Copy link
Contributor Author

@dgp1130 If nobody started working on it yet then I can do the mentioned changes for "type"

@dgp1130
Copy link
Collaborator

dgp1130 commented Feb 20, 2020

@sacgrover, I don't believe anyone else has started on this, so you're good to go!

sacgrover added a commit to sacgrover/angular-cli that referenced this pull request Feb 21, 2020
Currently, Component and Class have the options to add custom type. In the case of class, It's already working fine with  an empty string in type but in the case  of component When setting the type to an empty string the file names generated will contain an extra period (.) which breaks the flow.

With this PR, It will generate the files without an extra period (.)

Reference angular#16811 and angular#16891
sacgrover added a commit to sacgrover/angular-cli that referenced this pull request Feb 21, 2020
Currently, Component and Class have the options to add custom type. In the case of class, It's already working fine with  an empty string in type but in the case  of component When setting the type to an empty string the file names generated will contain an extra period (.) which breaks the flow.

With this PR, It will generate the files without an extra period (.)

Reference angular#16811 and angular#16891
@sacgrover
Copy link
Contributor Author

@dgp1130 I have opened another PR for this. #17040

sacgrover added a commit to sacgrover/angular-cli that referenced this pull request Feb 21, 2020
Currently, Component and Class have the options to add custom type. In the case of class, It's already working fine with  an empty string in type but in the case  of component When setting the type to an empty string the file names generated will contain an extra period (.) which breaks the flow.

With this PR, It will generate the files without an extra period (.)

Reference angular#16811 and angular#16891
sacgrover added a commit to sacgrover/angular-cli that referenced this pull request Feb 26, 2020
Currently, Component and Class have the options to add custom type. In the case of class, It's already working fine with  an empty string in type but in the case  of component When setting the type to an empty string the file names generated will contain an extra period (.) which breaks the flow.

With this PR, It will generate the files without an extra period (.)

Reference angular#16811 and angular#16891
@clydin clydin removed the needs: discussion On the agenda for team meeting to determine next steps label Feb 26, 2020
@clydin
Copy link
Member

clydin commented Feb 26, 2020

Closing as the work for this is progressing in the above mentioned PR.

@clydin clydin closed this Feb 26, 2020
dgp1130 pushed a commit that referenced this pull request Feb 26, 2020
Currently, Component and Class have the options to add custom type. In the case of class, It's already working fine with  an empty string in type but in the case  of component When setting the type to an empty string the file names generated will contain an extra period (.) which breaks the flow.

With this PR, It will generate the files without an extra period (.)

Reference #16811 and #16891
dgp1130 pushed a commit that referenced this pull request Feb 26, 2020
Currently, Component and Class have the options to add custom type. In the case of class, It's already working fine with  an empty string in type but in the case  of component When setting the type to an empty string the file names generated will contain an extra period (.) which breaks the flow.

With this PR, It will generate the files without an extra period (.)

Reference #16811 and #16891

Fixed minor merge conflict due to the lack of d6fa2bd in the release branch.

(cherry picked from commit 1c1f1cd)
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Mar 28, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow generation of suffix-free file and symbol names
6 participants