-
Notifications
You must be signed in to change notification settings - Fork 140
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 "--only-deps" flag to install command #546
Conversation
This extends the CLI, and provides a command to an additional public function, `install_requirements()`. This will skip installing the user's code, but will still install all required dependencies. This enables installation of dependencies without the need for separate `requirements.txt` files `flit install-reqs` The following command can be used instead of `pip install -r requirements.test.txt` `flit install-reqs --deps test`
I have been working with @brettcannon on a template for Python Projects using pyproject.toml. When converting, I removed my |
@takluyver do you have an feedback for this requested feature? |
Is anything blocking this from getting included? |
Hi, sorry it's taken me so long to look at this - life has been getting in the way. 🙂 I'm happy with the idea of exposing this, but I think I'd prefer to do so as an option for Poetry has the same thing as |
I've gone with |
changing the title so it accurate reflects the implementation. |
tl;dr We added
--only-deps
toflit install
The final implementation is slightly different than originally proposed. The final implementation enables the following command.
flit install --only-deps
Proposal
This extends the CLI, and provides a command wrapper for an additional public function,
install_requirements()
. This will skip installing the user's code, but will still install all required dependencies. This is particularly useful for preparing building images or containers by enabling users to pre-install dependencies, without installing the source code directly.This enables installation of dependencies without the need for separate requirements.txt files
flit install-reqs
The following command can be used instead of
pip install -r requirements.test.txt
orpip install .[test]
flit install-reqs --deps test
Open Issues
The following issues are present, because they are required for normal package installation, but are unnecessarily when installing the dependencies.