Repository navigation
Commit 6e485ba
authored
feat: add recursive directory support (#11)
* feat: add recursive directory support
Mirror source folder hierarchy (Artist/Album) in all output
directories. Flat source folders continue to work unchanged.
Closes #10
* fix: address CodeRabbit review feedback
- Handle directory move/delete events in watcher (clean mirrored subtrees)
- Guard orphan cleanup when source has no audio files (prevent data loss)
- Log exception in _cleanup_orphans instead of bare except
- Clean empty output subdirectories immediately on file deletion
- NFC-normalize directory paths in verify_sync get_rel_stem
- Add text language tag to README code fence
- Fix unused variable warnings (Ruff B007)
* fix: guard directory deletion against root/outside paths and unblock watcher thread
- Reject rel_dir=="." or ".." prefixes in _handle_directory_delete to prevent
wiping entire output directories when source root is deleted
- Add safety_guard_active check to directory-level deletions
- Offload directory move reprocessing to a background thread so the watchdog
dispatcher is not blocked by per-file sleep+encode
- Move os import to module scope, remove unused get_output_file_path import1 parent c6c94ed commit 6e485ba
11 files changed
Lines changed: 519 additions & 202 deletions
File tree
- .github/workflows
- docs
- src/audio_transcode_watcher
- tests
- tools
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
37 | 38 | | |
38 | 39 | | |
39 | 40 | | |
| |||
75 | 76 | | |
76 | 77 | | |
77 | 78 | | |
78 | | - | |
| 79 | + | |
79 | 80 | | |
80 | 81 | | |
81 | 82 | | |
| |||
106 | 107 | | |
107 | 108 | | |
108 | 109 | | |
109 | | - | |
| 110 | + | |
110 | 111 | | |
111 | 112 | | |
112 | 113 | | |
| |||
198 | 199 | | |
199 | 200 | | |
200 | 201 | | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
201 | 222 | | |
202 | 223 | | |
203 | 224 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
6 | 16 | | |
7 | 17 | | |
8 | | - | |
9 | | - | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
10 | 30 | | |
11 | 31 | | |
12 | 32 | | |
13 | 33 | | |
14 | 34 | | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
20 | 38 | | |
21 | | - | |
22 | | - | |
23 | | - | |
| 39 | + | |
24 | 40 | | |
25 | | - | |
26 | | - | |
27 | | - | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
28 | 44 | | |
29 | | - | |
30 | | - | |
31 | | - | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
32 | 48 | | |
33 | 49 | | |
34 | 50 | | |
35 | 51 | | |
36 | 52 | | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | 53 | | |
68 | 54 | | |
69 | 55 | | |
70 | 56 | | |
71 | | - | |
72 | 57 | | |
73 | | - | |
| 58 | + | |
74 | 59 | | |
75 | 60 | | |
76 | | - | |
77 | 61 | | |
78 | | - | |
79 | 62 | | |
80 | 63 | | |
81 | 64 | | |
82 | 65 | | |
83 | 66 | | |
84 | | - | |
85 | | - | |
86 | 67 | | |
87 | 68 | | |
88 | | - | |
89 | 69 | | |
90 | 70 | | |
91 | 71 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
8 | 10 | | |
9 | 11 | | |
10 | 12 | | |
| |||
0 commit comments