Build¶
Description¶
Build task is used to build a Python distribution. The Setup or SetupPy2exe task have to be called prior to <build> to create the setup.py file.
Warning
This task requires that the installation of Python and that it can be called from the command line.
Warning
This task requires that the installation of the Python’s package setuptools or distribute.
Parameters¶
Attribute | Description | Required |
---|---|---|
dir | Directory containing the distribution source code and a setup.py file. | yes |
todir | Directory where the build files will be saved. | yes |
command | Build command (e.g. sdist, bdist, bdist_wininst, bdist_egg, etc.). | yes |
Examples¶
To build a source distribution:
<!-- setup task -->
<build dir="${path.to.package}" todir="${dist.dir}" command="sdist" />
This task is equivalent to executing the following command:
cd ${path.to.package}
python setup.py sdist -d ${dist.dir}