-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Custom Generator Presets cannot take arguments with strings that have spaces in them #15995
Comments
Not sure if it is related or not, but I have a similar issue with arguments with spaces for nx run:
It should keep the why o why as one string preferably. |
Any updates on this issue? |
This issue has been automatically marked as stale because it hasn't had any recent activity. It will be closed in 14 days if no further activity occurs. |
This still is an issue. |
I am having the same issue as @ksjogo with args, but for args specified in It seems like there might be a recurring issue where |
I encountered this as well. If an argument value of a custom generator contains a space, NX only inserts the part of the string till the space is reached.
If |
Current Behavior
When I pass in an argument with a custom preset that is type string, and has a space in it, the generator does not properly take in the string argument.
The string argument is split by spaces, and therefore preset generators that take in strings are broken if there is a space in the string.
Expected Behavior
Notice how string arguments with spaces in them correctly go with the argument
GitHub Repo
No response
Steps to Reproduce
In the Nx logger, it outputs that it will run the following:
Notice how
Therefore, name is treated as an unnamed argument, when it was originally in the string and should be in
--name
Nx Report
Failure Logs
Notice how
Where it should be
Additional Information
I found a line of code that is causing the issue. It is this line
https://github.com/nrwl/nx/blob/15.9.1/packages/create-nx-workspace/src/create-preset.ts#L52
Since the command is splitting the string by spaces, spaces within the string arguments are separated incorrectly. It should not separate argument string with spaces inside of them
The text was updated successfully, but these errors were encountered: