@@ -19,6 +19,8 @@ information that's already documented for Python in the
1919 :local:
2020
2121
22+ .. _setupcfg-syntax :
23+
2224Syntax
2325======
2426
@@ -117,6 +119,8 @@ from most specialized to most common.
117119file **. This will be useful to let users publish a single file.
118120
119121
122+ .. _setupcfg-sections :
123+
120124Description of sections and fields
121125==================================
122126
@@ -149,6 +153,8 @@ command sections
149153 on the command line.
150154
151155
156+ .. _setupcfg-section-global :
157+
152158Global options
153159--------------
154160
@@ -194,6 +200,9 @@ setup_hooks
194200 setup_hooks = _setuphooks.customize_config
195201
196202
203+
204+ .. _setupcfg-section-metadata :
205+
197206Metadata
198207--------
199208
@@ -318,14 +327,17 @@ You should not give any explicit value for metadata-version: it will be guessed
318327from the fields present in the file.
319328
320329
330+ .. _setupcfg-section-files :
331+
321332Files
322333-----
323334
324335This section describes the files included in the project.
325336
326337packages_root
327338 the root directory containing all packages and modules
328- (default: current directory). *optional *
339+ (default: current directory, i.e. the project's top-level
340+ directory where :file: `setup.cfg ` lives). *optional *
329341
330342packages
331343 a list of packages the project includes *optional *, *multi *
@@ -337,8 +349,8 @@ scripts
337349 a list of scripts the project includes *optional *, *multi *
338350
339351extra_files
340- a list of patterns to include extra files * optional *,
341- *multi *
352+ a list of patterns for additional files to include in source distributions
353+ (see :ref: ` packaging-manifest `) * optional *, *multi *
342354
343355Example::
344356
@@ -747,8 +759,10 @@ We use brace expansion syntax to place all the shell and batch scripts into
747759{scripts} category.
748760
749761
750- Extension sections
751- ------------------
762+ .. _setupcfg-section-extensions :
763+
764+ Extension modules sections
765+ --------------------------
752766
753767If a project includes extension modules written in C or C++, each one of them
754768needs to have its options defined in a dedicated section. Here's an example::
@@ -779,8 +793,10 @@ addition, multi-line values accept environment markers on each line, after a
779793``-- ``.
780794
781795
782- Command sections
783- ----------------
796+ .. _setupcfg-section-commands :
797+
798+ Commands sections
799+ -----------------
784800
785801To pass options to commands without having to type them on the command line
786802for each invocation, you can write them in the :file: `setup.cfg ` file, in a
@@ -803,6 +819,11 @@ section named after the command. Example::
803819Option values given in the configuration file can be overriden on the command
804820line. See :ref: `packaging-setup-config ` for more information.
805821
822+ These sections are also used to define :ref: `command hooks
823+ <packaging-command-hooks>`.
824+
825+
826+ .. _setupcfg-extensibility :
806827
807828Extensibility
808829=============
@@ -817,6 +838,8 @@ An extension field starts with ``X-``. Example::
817838 X-Debian-Name = python-distribute
818839
819840
841+ .. _setupcfg-changes :
842+
820843Changes in the specification
821844============================
822845
@@ -852,6 +875,8 @@ A tool written to produce 1.x should have these properties:
852875- May write optional fields.
853876
854877
878+ .. _setupcfg-acks :
879+
855880Acknowledgments
856881===============
857882
0 commit comments