Commit graph

2 commits

Author SHA1 Message Date
LE Manh Cuong
8544b2f0f5 Allow directory with trailing and leading spaces
- The `sanitize_path_options` functions remove all trailing
 and leading spaces. So any valid directory like ` 123`,
 `123 ` can not be used

 - Also if there are two directories ` 123` and `123`, and if
 user pick the ` 123` as option to `-d` or `-t`, then stow pick
 directory `123` as the argument instead of ` 123` as user want.

    ```
    STOW_DIR=. stow -n -v3 -t \ 123 456
    stow dir is /tmp/test
    stow dir path relative to target 123 is ..
    cwd now 123
    cwd restored to /tmp/test
    cwd now 123
    Planning stow of package 456...
    Stowing contents of ../456 (cwd=/tmp/test/123)
    Planning stow of package 456... done
    cwd restored to /tmp/test
    WARNING: in simulation mode so not modifying filesystem.
    ```
 - This commit remove the check in `sanitize_path_options` function,
 and now stow can work with those directories. There have been a check
 for valid directory, so we are safe.
2015-11-13 20:17:58 +07:00
Adam Spiers
c3c866a00b Rename stow.t to be more consistent with its purpose. 2012-01-09 22:12:49 +00:00
Renamed from t/stow.t (Browse further)