Closed juergenhoetzel closed 8 years ago
Thanks for the contribution, @juergenhoetzel.
I tested your changes and I get this error:
$ sup development config
user@example.com:22 | + tar -C /tmp/ -xzf -
user@example.com:22 |
user@example.com:22 | gzip: stdin: decompression OK, trailing garbage ignored
user@example.com:22 | tar: Child returned status 2
user@example.com:22 | tar: Error is not recoverable: exiting now
user@example.com:22 | exit 2
$ sup development config user@example.com:22 | + tar -C /tmp/ -xzf - user@example.com:22 | user@example.com:22 | gzip: stdin: decompression OK, trailing garbage ignored user@example.com:22 | tar: Child returned status 2 user@example.com:22 | tar: Error is not recoverable: exiting now user@example.com:22 | exit 2
@VojtechVitek The Environment isn't passed in my branch: So the
- src: ./example.$SUP_NETWORK.cfg
will not be substituted.
I will close this request. It will not work if you use environment variables.
A proper solution needs to handle environment variables in a cross-platform way as described: https://github.com/pressly/sup/issues/59
Interesting, so that's why I probably used bash instead of tar in the first place. I should have documented it better.
I wonder if we could substitute the env vars locally for file names and use tar/rsync directly. Thanks for investigating this issue.
Fixes issues with whitespace or special shell characters in path or excludes.
Also fixes portability issues: Bash is not the default shell on *BSD systems.