From: Andreas Schneider Date: Mon, 24 Jun 2024 13:14:43 +0000 (+0200) Subject: examples: Use cp with force option X-Git-Tag: tdb-1.4.11~273 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c814681c6b965b15b3d4895cc0d47f01ba2c31d3;p=thirdparty%2Fsamba.git examples: Use cp with force option "Error: SHELLCHECK_WARNING: /usr/share/doc/samba/printing/VampireDriversFunctions:951:15: warning[SC2216]: Piping to 'cp', a command that doesn't read stdin. Wrong command or missing xargs? 949| CWD2=""$( pwd )"" ; 950| cd ""${i}""; 951|-> echo ""yes"" | cp ../alldriverfiles.txt . 2> /dev/null ; 952| 953| cat alldriverfiles.txt \" Signed-off-by: Andreas Schneider Reviewed-by: Noel Power --- diff --git a/examples/printing/VampireDriversFunctions b/examples/printing/VampireDriversFunctions index b06e3653214..6580f0a2dc6 100644 --- a/examples/printing/VampireDriversFunctions +++ b/examples/printing/VampireDriversFunctions @@ -948,7 +948,7 @@ else for i in */; do CWD2="$( pwd )" ; cd "${i}"; - echo "yes" | cp ../alldriverfiles.txt . 2> /dev/null ; + cp -f ../alldriverfiles.txt . 2> /dev/null ; cat alldriverfiles.txt \ | egrep '(\\'"$(basename "$( pwd )")"'\\|Driver Name)' \ @@ -1076,7 +1076,7 @@ else echo " " echo " ###########################################################################################" -###### echo "yes" | cp -f ../../../${nthost}/W32X86/${nthost}-enumdrivers3list-NTx86.txt . 2> /dev/null ; +###### cp -f ../../../${nthost}/W32X86/${nthost}-enumdrivers3list-NTx86.txt . 2> /dev/null ; ln -s -f ../${nthost}-enumdrivers3list-NTx86.txt ${nthost}-enumdrivers3list-NTx86.lnk ; tac ${nthost}-enumdrivers3list-NTx86.lnk \ @@ -1095,7 +1095,7 @@ else for i in */; do CWD2="$( pwd )" ; cd "${i}"; - echo "yes" | cp ../alldriverfiles.txt . 2> /dev/null ; + cp -f ../alldriverfiles.txt . 2> /dev/null ; cat alldriverfiles.txt \ | egrep '(\\'"$(basename "$( pwd )")"'\\|Driver Name)' \