-
Notifications
You must be signed in to change notification settings - Fork 296
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
If the source for a link is null, use the basename of the destination with a single leading '.' removed, if present.
- Loading branch information
1 parent
b482cbd
commit d2e20c7
Showing
3 changed files
with
81 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
test_description='link uses destination if source is null' | ||
. '../test-lib.bash' | ||
|
||
test_expect_success 'setup' ' | ||
echo "apple" > ${DOTFILES}/f && | ||
echo "grape" > ${DOTFILES}/fd | ||
' | ||
|
||
test_expect_success 'run' ' | ||
run_dotbot <<EOF | ||
- link: | ||
~/f: | ||
~/.f: | ||
~/fd: | ||
force: false | ||
~/.fd: | ||
force: false | ||
EOF | ||
' | ||
|
||
test_expect_success 'test' ' | ||
grep "apple" ~/f && | ||
grep "apple" ~/.f && | ||
grep "grape" ~/fd && | ||
grep "grape" ~/.fd | ||
' |