summaryrefslogtreecommitdiff
path: root/test/rcrc-tilde.t
diff options
context:
space:
mode:
authorGravatar Rebecca Meritz <rebecca@meritz.com>2017-10-25 23:46:43 -0400
committerGravatar Mike Burns <mburns@thoughtbot.com>2017-10-27 14:51:01 -0400
commitd2e4daba376dcb96c1cad5fd89413f154a8c4a10 (patch)
tree44e180abdee5e0e21881f1eb8d36ba7c10b2cf23 /test/rcrc-tilde.t
parent95e6ca15aabd71ac1709ddb5e10e3baa11eeee66 (diff)
Expand ~ in DOTFILES_DIRS
Hat tip to fgatham for the `eval echo` tip. This means both `~` and e.g. `~dmr` work correctly.
Diffstat (limited to 'test/rcrc-tilde.t')
-rw-r--r--test/rcrc-tilde.t10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/rcrc-tilde.t b/test/rcrc-tilde.t
new file mode 100644
index 0000000..b3f98c1
--- /dev/null
+++ b/test/rcrc-tilde.t
@@ -0,0 +1,10 @@
+ $ . "$TESTDIR/helper.sh"
+
+rcrc should accept a DOTFILES_DIR with a ~ instead of $HOME
+
+ $ mkdir ~/.other-dotfiles
+ > touch ~/.other-dotfiles/o-example
+
+ $ echo 'DOTFILES_DIRS="~/.other-dotfiles"' > alt-rcrc
+ $ RCRC=./alt-rcrc lsrc
+ /*/.o-example:/*/.other-dotfiles/o-example (glob)