[Build][Bug] Fix apt-get remove version not lock issue (#12193)
Why I did it Fix apt-get remove/purge version not locked issue when the apt-get options not specified. How I did it Add a space character before and after the command line parameters.
This commit is contained in:
parent
56c41cbede
commit
ed20a6dec6
@ -20,7 +20,7 @@ if [ "$INSTALL" == y ]; then
|
||||
[ "$lock_result" == y ] && release_apt_installation_lock
|
||||
exit $command_result
|
||||
else
|
||||
if [[ "$1" == "purge" || "$@" == *" purge "* ]]; then
|
||||
if [[ " $@ " == *" purge "* || " $@ " == *" remove "* ]]; then
|
||||
# When running the purge command, collect the debian versions
|
||||
dpkg-query -W -f '${Package}==${Version}\n' >> $POST_VERSION_PATH/purge-versions-deb
|
||||
chmod a+wr $POST_VERSION_PATH/purge-versions-deb
|
||||
|
Loading…
Reference in New Issue
Block a user