Re:A Better Pip Workflow
by falsedan on Wednesday March 02, 2016 @12:38PM
(#11211507)
This is easily the best option, barring how painful it is to write a setup.py.
[ Parent
| on HN ]
Filling out setup.py and other package boilerplate used to annoy me as well but that all changed after I started using cookiecutter.
Thanks! I use cookiecutter and I still have to tweak things like MANIFEST.in and adding the package to the path while installing, for automatically-created entry points.
It's really not that bad with setuptools - as an added bonus it becomes easy to package your application up in an RPM.
setuptools? distutils you mean?
I much prefer fpm for creating Linux distro packaged from a python distribution, since it can create debs.
No, I mean setuptools - it does everything distutils does but better.
I don't trust random scripts to generate packages for me, writing an rpmspec or a debian control file is hardly a challenge and I'd encourage more people to take the 5 minutes to do so than relying on tools like FPM.
… or tools like setuptools?
Also, I assume you're talking about the bdist_rpm target that come from distutils.
No, I write a proper RPM spec file - only takes a few minutes.
So, what's the added bonus of using setuptools then?
setuptools is just less generally crufty than distutils, and things like entrypoints make writing installable console scripts feasible. Since it provides essentially the same interface the default rpmspec created by rpmdev-newspec works with it out of the box.