File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 7
7
8
8
set -o pipefail
9
9
10
- # Filter vanished file warnings from stderr. The complex redirections are
11
- # necessary to filter stderr while also keeping stdout and stderr separated.
10
+ # Filter vanished file warnings from both stdout (rsync versions < 3.x) and
11
+ # stderr (rsync versions >= 3.x). The complex redirections are necessary to
12
+ # filter stderr while also keeping stdout and stderr separated.
12
13
IGNOREOUT=' ^(file has vanished: |rsync warning: some files vanished before they could be transferred)'
13
14
(rsync " ${@ } " 3>&1 1>&2 2>&3 3>& - |
14
- (egrep -v " $IGNOREOUT " || true)) 3>&1 1>&2 2>&3 3>& -
15
+ (egrep -v " $IGNOREOUT " || true)) 3>&1 1>&2 2>&3 3>& - |
16
+ (egrep -v " $IGNOREOUT " || true)
15
17
res=$?
16
18
17
19
# rsync exits with 24 when vanished files are detected.
You can’t perform that action at this time.
0 commit comments