mirror of
https://github.com/ViViDboarder/shoestrap.git
synced 2024-11-21 21:06:32 +00:00
Merge pull request #2 from adam12/fix/apt-commands
Fix commands for apt package manager.
This commit is contained in:
commit
153bfb1bd7
@ -163,7 +163,7 @@ package () {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$PACKAGE_MANAGER" == 'apt-get' ]; then
|
if [ "$PACKAGE_MANAGER" == 'apt-get' ]; then
|
||||||
DEBIAN_FRONTEND=noninteractive apt-get install -y $1
|
DEBIAN_FRONTEND=noninteractive apt-get install -y --force-yes $1
|
||||||
elif [ "$PACKAGE_MANAGER" == 'yum' ]; then
|
elif [ "$PACKAGE_MANAGER" == 'yum' ]; then
|
||||||
yum install -y $1
|
yum install -y $1
|
||||||
elif [ "$PACKAGE_MANAGER" == 'brew' ]; then
|
elif [ "$PACKAGE_MANAGER" == 'brew' ]; then
|
||||||
@ -193,7 +193,7 @@ test_package_installed () {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$PACKAGE_MANAGER" == 'apt-get' ]; then
|
if [ "$PACKAGE_MANAGER" == 'apt-get' ]; then
|
||||||
dpkg -l $1
|
dpkg-query -l "$1" | grep -q ^.i
|
||||||
return $?
|
return $?
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user