t4041 (diff-submodule-option): rewrite add_file() routine
authorRamkumar Ramachandra <artagnon@gmail.com>
Fri, 30 Nov 2012 11:37:35 +0000 (17:07 +0530)
committerJunio C Hamano <gitster@pobox.com>
Sun, 2 Dec 2012 10:02:05 +0000 (02:02 -0800)
commit2934975f2df4ab7fd93c0f7a2fff80414d090547
treea8fcc0e0c403de2e0293d716c9b0541e0760efa7
parent20fa53855e5479e9903047ba18cc247fd4519db4
t4041 (diff-submodule-option): rewrite add_file() routine

Instead of "cd there and then come back", use the "cd there in a
subshell" pattern.  Also fix '&&' chaining in one place.

Suggested-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t4041-diff-submodule-option.sh