mirror of
https://github.com/beetbox/beets.git
synced 2025-12-24 17:43:52 +01:00
Fix 1583: Move command only shows modified files
This commit is contained in:
parent
e9cfae9369
commit
50789e88fe
3 changed files with 9 additions and 2 deletions
|
|
@ -1427,11 +1427,16 @@ def move_items(lib, dest, query, copy, album, pretend):
|
|||
"""
|
||||
items, albums = _do_query(lib, query, album, False)
|
||||
objs = albums if album else items
|
||||
isitemmoved = lambda item: item.path != item.destination(basedir=dest)
|
||||
isalbummoved = lambda album: any(isitemmoved(i) for i in album.items())
|
||||
objs = [o for o in objs if (isalbummoved if album else isitemmoved)(o)]
|
||||
|
||||
action = 'Copying' if copy else 'Moving'
|
||||
entity = 'album' if album else 'item'
|
||||
log.info(u'{0} {1} {2}{3}.', action, len(objs), entity,
|
||||
's' if len(objs) > 1 else '')
|
||||
's' if len(objs) != 1 else '')
|
||||
if len(objs) == 0:
|
||||
return
|
||||
if pretend:
|
||||
if album:
|
||||
show_path_changes([(item.path, item.destination(basedir=dest))
|
||||
|
|
|
|||
|
|
@ -22,6 +22,8 @@ Fixes:
|
|||
generated ``.m3u`` files beforehand either.). If this is an issue for you, you
|
||||
might want to take a look at the ``raw`` config option of the
|
||||
:doc:`/plugins/play`. :bug:`1785`, :bug:`1600`
|
||||
* The :ref:`move-cmd` command does not display files whose path does not change
|
||||
anymore. :bug:`1583`
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -256,7 +256,7 @@ anywhere in your filesystem. The ``-c`` option copies files instead of moving
|
|||
them. As with other commands, the ``-a`` option matches albums instead of items.
|
||||
|
||||
To perform a "dry run", just use the ``-p`` (for "pretend") flag. This will
|
||||
show you all how the files would be moved but won't actually change anything
|
||||
show you a list of files that would be moved but won't actually change anything
|
||||
on disk.
|
||||
|
||||
.. _update-cmd:
|
||||
|
|
|
|||
Loading…
Reference in a new issue