Back to Spacedrive

Location Management Actions

.tasks/core/LOC-001-location-management-actions.md

0.4.3926 B
Original Source

Description

The core actions for managing library locations will be implemented. This includes adding a new directory to be indexed, removing it, and triggering a rescan.

Implementation Notes

  • Add: The LocationAddAction (src/operations/locations/add/action.rs) creates a location record and dispatches an initial IndexerJob.
  • Remove: The LocationRemoveAction (src/operations/locations/remove/action.rs) removes the location and all its associated entries from the database.
  • Rescan: The LocationRescanAction (src/operations/locations/rescan/action.rs) dispatches a new IndexerJob for an existing location.

Acceptance Criteria

  • A user can add a new local directory as a location.
  • Adding a location automatically starts an indexing job.
  • A user can remove a location, cleaning up its database entries.
  • A user can trigger a manual rescan of an existing location.