MCPcopy Index your code
hub / github.com/beetbox/beets / edit

Method edit

beetsplug/edit.py:208–221  ·  view source on GitHub ↗

The core editor function. - `album`: A flag indicating whether we're editing Items or Albums. - `objs`: The `Item`s or `Album`s to edit. - `fields`: The set of field names to edit (or None to edit everything).

(self, album, objs, fields)

Source from the content-addressed store, hash-verified

206 return set(fields)
207
208 def edit(self, album, objs, fields):
209 """The core editor function.
210
211 - `album`: A flag indicating whether we're editing Items or Albums.
212 - `objs`: The `Item`s or `Album`s to edit.
213 - `fields`: The set of field names to edit (or None to edit
214 everything).
215 """
216 # Present the YAML to the user and let them change it.
217 success = self.edit_objects(objs, fields)
218
219 # Save the new data.
220 if success:
221 self.save_changes(objs)
222
223 def edit_objects(self, objs, fields):
224 """Dump a set of Model objects to a file as text, ask the user

Callers 1

_edit_commandMethod · 0.95

Calls 2

edit_objectsMethod · 0.95
save_changesMethod · 0.95

Tested by

no test coverage detected