Skip to content

Commit

Permalink
fix: redirect stderr to stdout to apply ignoring greps
Browse files Browse the repository at this point in the history
  • Loading branch information
moul committed May 25, 2018
1 parent f542707 commit a820c3d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docker-diff
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ mkdir -p ${tmpdir}/${IMAGE_A} && tar -xf ${tmpdir}/A.tar -C ${tmpdir}/${IMAGE_A}
mkdir -p ${tmpdir}/${IMAGE_B} && tar -xf ${tmpdir}/B.tar -C ${tmpdir}/${IMAGE_B} --exclude='./etc/mtab' --exclude='./proc' --exclude='./dev'
(
cd ${tmpdir}
diff --unified -arq ${IMAGE_A} ${IMAGE_B} | grep -v "No such file or directory" | grep -v "is a character special file" | grep -v "is a block special file" | tee ${tmpdir}/diff
diff --unified -arq ${IMAGE_A} ${IMAGE_B} 2>&1 | grep -v "No such file or directory" | grep -v "is a character special file" | grep -v "is a block special file" | tee ${tmpdir}/diff
)
cat ${tmpdir}/diff | wc -l > ${tmpdir}/difflinecount
set +e
Expand Down

0 comments on commit a820c3d

Please sign in to comment.