summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Honz <exislow+github@gmail.com>2025-01-04 12:51:17 +0100
committerRobert Honz <exislow+github@gmail.com>2025-01-04 12:51:17 +0100
commitc0ca74811949d88158b6e6dbddf7cb54f8e0f543 (patch)
tree65dd36ae03b97fa10025b274fd6748d37e9c4012
parent5012c5d4de84e0c8f05377029f63e4cc6e9ad53a (diff)
downloadtidal-dl-ng-c0ca74811949d88158b6e6dbddf7cb54f8e0f543.tar.gz
👷 Tracks will be linked relatively within the download folder.
-rw-r--r--tidal_dl_ng/download.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/tidal_dl_ng/download.py b/tidal_dl_ng/download.py
index 6175e4c..124d6f0 100644
--- a/tidal_dl_ng/download.py
+++ b/tidal_dl_ng/download.py
@@ -495,8 +495,10 @@ class Download:
if not skip_symlink:
self.fn_logger.debug(f"Symlink: {path_media_src} -> {path_media_dst}")
+ path_media_dst_relative: pathlib.Path = path_media_dst.relative_to(path_media_src.parent, walk_up=True)
+
path_media_src.unlink(missing_ok=True)
- path_media_src.symlink_to(path_media_dst)
+ path_media_src.symlink_to(path_media_dst_relative)
return path_media_dst