Build a wheel/egg and all dependencies for a python project

后端 未结 2 1879
迷失自我
迷失自我 2020-12-12 11:10

In order to stage python project within our corporation I need to make an installable distribution.

This should include:

  • An egg or whl for my project<
2条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-12 11:16

    With the latest pip and wheel, you can simply run

    pip wheel .
    

    within your project folder, even if your application isn't on PyPi. All wheels will be stored in the current directory (.).

    To change the output directory (to for example, ./wheels), you may use the -w / --wheel-dir option:

    pip wheel . -w wheels
    

    All the options available are listed at the pip documentation.

提交回复
热议问题