allow triggering indexing from xau hook based on absolute path
- Lingua principale
- Python
- Stelle
- 46.6k
- Fork
- 1.9k
- Merge medio
- 10g 16h
- PR unite (30g)
- 5
Descrizione
**is your feature request related to a problem? Please describe.**
currently, `xau` hooks that create new files can trigger indexing by printing (e.g.) `json.dumps({"idx":{"vp":["/foo/1.txt","/foo/bar/2.txt"]}})`
in this syntax, absolute paths are relative to the root of the volume, relative paths are relative to the file that triggered the hook. however, sometimes it is more convenient to use the absolute path (for example, because the hook just passed it to an external tool that needed the absolute path anyway)
**Describe the idea / solution you'd like**
support the following syntax: `"idx": {"ap": ["/home/me/copyparty/cool-files/new-file.txt"]}`, which then should cause copyparty to index that file the same as if it were triggered via a volume path
this should probably also support `reloc` and maybe `del` (making sure that this doesn't cause copyparty to delete files outside any volume), but I don't have a specific use for these
**Describe any alternatives you've considered**
i just let the normal indexer deal with it
**Additional Context**
I think this behaviour is handled here: https://github.com/9001/copyparty/blob/27031f73be12071625c93ab231eb0235b74b2c04/copyparty/up2k.py#L5646-L5650
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.