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

Add project slug name to neuro project init #1254

Merged
merged 3 commits into from
Dec 17, 2019

Conversation

anayden
Copy link
Contributor

@anayden anayden commented Dec 17, 2019

Closes #1230

@anayden anayden requested a review from asvetlov December 17, 2019 14:10
@anayden anayden merged commit fcd9ee2 into master Dec 17, 2019
@anayden anayden deleted the an/1230-project-init-set-dir branch December 17, 2019 15:18
@serhiy-storchaka
Copy link
Contributor

Would not the -q option be confused with the global -q option: neuro -q project init and neuro project init -q?

@anayden
Copy link
Contributor Author

anayden commented Dec 18, 2019

This option is not necessary for users: you normally wouldn't want to create a project with default cookiecutter settings (especially, project name). It's only needed in tests.

@asvetlov
Copy link
Contributor

Good catch!
I suggest renaming the option with --no-input, two options with the same name but different meaning is very confusing.
Also, please consider hidden=True for the debug-only option.

@atemate
Copy link
Contributor

atemate commented Dec 18, 2019

Personally, I disagree with disabling input for neuro project init -- we introduced this only to facilitate tests, but in fact this breaks the intended logic -- even if project-slug is defined, project-name and code directory will remain default. So let's drop -q functionality until it's released.

@anayden
Copy link
Contributor Author

anayden commented Dec 18, 2019

I don't follow. What's wrong with having this option again?

@asvetlov
Copy link
Contributor

Regarding -q naming: consider neuro -q project init -q slug.
The first -q has totally different meaning that the second -q.
That's why I object. If we absolutely need this option for testing -- let's rename and hide it.
I don't follow cookiecutter-template project too tightly for deciding if the option needed at all or not.
@ayushkovskiy and @anayden please make an agreement on it.

@atemate
Copy link
Contributor

atemate commented Dec 18, 2019

I don't follow. What's wrong with having this option again?

neuro project init -q custom-slug is equivalent to

project_name [Name of the project]: 
project_slug [custom-slug]: 
code_directory [modules]: 

so with -q there's no way to set up project_name and code_directory.
And in case of neuro project init -q, project_slug will also become default name-of-the-project, which might be surprising for a user.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make it easier to determine new project directory after neuro project init
5 participants