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

implement add_new #2

Open
AdamGold opened this issue Jan 13, 2019 · 0 comments
Open

implement add_new #2

AdamGold opened this issue Jan 13, 2019 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@AdamGold
Copy link
Owner

AdamGold commented Jan 13, 2019

if add_new=True, a generator will be made of all top tree dependencies - filtered by only non existing packages in setup.py. Then, add them (by regex, maybe AST in the future) to install_requires by the following logic:

  1. search for install_requires=
  2. search for the next comma that isn't followed by quotes (for example:
    install_requires=['test', 'test2'], # THIS COMMA test_requires)
  3. ask the user if he/she wants to add all non existing packages or loop through.
    if all - just make a list from the generator and add before that comma. If it's a loop, loop through the generator, asking the user whether to add a specific package each time - make a list and add before that comma.
  4. write to setup.py
@AdamGold AdamGold added the enhancement New feature or request label Jan 15, 2019
@AdamGold AdamGold self-assigned this Jan 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant