-
-
Notifications
You must be signed in to change notification settings - Fork 29
Open
Description
Summary
When running the install script (bash -ixc "$(curl -fsSL https://dorothy.bevry.me/install)"
), I receive the following error:
+ ln -sfF -- /Users/jondpenton/.local/share/dorothy /Users/jondpenton/.local/share/dorothy
ln: /Users/jondpenton/.local/share/dorothy: Directory not empty
Debug Log
Potential Solution
I was able to get dorothy install
and setup-system update
working by applying the following changes to commands/dorothy
:
diff --git a/commands/dorothy b/commands/dorothy
index a9a12f91..d91a2e28 100755
--- a/commands/dorothy
+++ b/commands/dorothy
@@ -667,15 +667,19 @@ function dorothy_() (
function relocate_then_symlink_if_necessary {
local symlink="$1" destination="$2"
relocate_if_necessary "$symlink" "$destination"
- if __is_alpine; then
- # alpine doesn't support -F, however the removals of relocate_if_necessary should make it unnecessary
- ln -sf -- "$destination" "$symlink"
- else
- # -F: replace symlink if directory if needed
- # -f: unlink symlink path if needed
- # -s: symbolic link
- ln -sfF -- "$destination" "$symlink"
+
+ if [[ "$symlink" != "$destination" ]]; then
+ if __is_alpine; then
+ # alpine doesn't support -F, however the removals of relocate_if_necessary should make it unnecessary
+ ln -sf -- "$destination" "$symlink"
+ else
+ # -F: replace symlink if directory if needed
+ # -f: unlink symlink path if needed
+ # -s: symbolic link
+ ln -sfF -- "$destination" "$symlink"
+ fi
fi
+
# cleanup accidents
symlink="$symlink/$(basename -- "$destination")"
if [[ -L $symlink ]]; then
Metadata
Metadata
Assignees
Labels
No labels