mirror of
https://github.com/octoleo/lsyncd.git
synced 2024-11-12 08:06:27 +00:00
17 lines
398 B
Bash
17 lines
398 B
Bash
|
#!/bin/bash
|
||
|
# copyright 2008 Junichi Uekawa <dancer@debian.org>
|
||
|
# licensed under GPLv2 or later, see the file ../COPYING for details.
|
||
|
|
||
|
# make sure that program exits with exit code of -1 when rsync path is
|
||
|
# wrong.
|
||
|
|
||
|
WORKTARGET=$(mktemp -d)
|
||
|
./lsyncd --no-daemon --rsync-binary /wrong/path/to/rsync . "${WORKTARGET}"
|
||
|
if [[ $? = 255 ]]; then
|
||
|
rmdir "${WORKTARGET}"
|
||
|
exit 0;
|
||
|
else
|
||
|
exit 1;
|
||
|
fi
|
||
|
|