Skip to content

Commit 71d6dc3

Browse files
committed
Docs refinements for #2581
1 parent 3f68445 commit 71d6dc3

File tree

3 files changed

+12
-18
lines changed

3 files changed

+12
-18
lines changed

docs/changelog.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ Changelog
66

77
Features:
88

9-
* It is now possible to set fields to certain values during import, using
10-
either the `importer.set_fields` dictionary in the config file, or by
11-
passing one or more `--set field=value` options on the command-line.
12-
:bug: `1881`
9+
* You can now set fields to certain values during :ref:`import-cmd`, using
10+
either a ``--set field=value`` command-line flag or a new :ref:`set_fields`
11+
configuration option under the `importer` section.
12+
Thanks to :user:`bartkl`. :bug: `1881` :bug:`2581`
1313
* :ref:`Date queries <datequery>` can now include times, so you can filter
1414
your music down to the second. Thanks to :user:`discopatrick`. :bug:`2506`
1515
:bug:`2528`

docs/reference/cli.rst

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -138,16 +138,13 @@ Optional command flags:
138138
searching for other candidates by using the ``--search-id SEARCH_ID`` option.
139139
Multiple IDs can be specified by simply repeating the option several times.
140140

141-
* You can supply ``--set`` options with ``field=value`` pairs to assign to
142-
those fields the specified values on import, in addition to such field/value
143-
pairs defined in the ``importer.set_fields`` dictionary in the configuration
144-
file. Make sure to use an option per field/value pair, like so::
141+
* You can supply ``--set field=value`` to assign `field` to `value` on import.
142+
These assignments will merge with (and possibly override) the
143+
:ref:`set_fields` configuration dictionary. You can use the option multiple
144+
times on the command line, like so::
145145

146146
beet import --set genre="Alternative Rock" --set mood="emotional"
147147

148-
Note that values for the fields specified on the command-line override the
149-
ones defined for those fields in the configuration file.
150-
151148
.. _rarfile: https://pypi.python.org/pypi/rarfile/2.2
152149

153150
.. only:: html

docs/reference/config.rst

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -591,18 +591,15 @@ Default: ``no``.
591591
set_fields
592592
~~~~~~~~~~
593593

594-
A dictionary of field/value pairs, each one used to set a field to the
595-
corresponding value during import.
596-
597-
Example: ::
594+
A dictionary indicating fields to set to values for newly imported music.
595+
Here's an example::
598596

599597
set_fields:
600598
genre: 'To Listen'
601599
collection: 'Unordered'
602600

603-
Note that field/value pairs supplied via ``--set`` options on the
604-
command-line are processed in addition to those specified here. Those values
605-
override the ones defined here in the case of fields with the same name.
601+
Other field/value pairs supplied via the ``--set`` option on the command-line
602+
override any settings here for fields with the same name.
606603

607604
Default: ``{}`` (empty).
608605

0 commit comments

Comments
 (0)