@ -112,7 +112,7 @@ class PackageManager:
def run ( self , script ) :
def run ( self , script ) :
if script != " " :
if script != " " :
check_target_env_call ( scr t ip. split ( " " ) )
check_target_env_call ( scr ipt . split ( " " ) )
def subst_locale ( list ) :
def subst_locale ( list ) :
@ -138,13 +138,13 @@ def run_operations(pkgman, entry):
for key in entry . keys ( ) :
for key in entry . keys ( ) :
entry [ key ] = subst_locale ( entry [ key ] )
entry [ key ] = subst_locale ( entry [ key ] )
if key == " install " :
if key == " install " :
if isinstance ( package , str ) :
if isinstance ( entry [ key ] , list ) :
pkgman . install ( entry [ key ] )
else :
for package in entry [ key ] :
for package in entry [ key ] :
pkgman . run ( package [ " pre-script " ] )
pkgman . run ( package [ " pre-script " ] )
pkgman . install ( [ package [ " package " ] ] )
pkgman . install ( [ package [ " package " ] ] )
pkgman . run ( package [ " post-script " ] )
pkgman . run ( package [ " post-script " ] )
else :
pkgman . install ( entry [ key ] )
elif key == " try_install " :
elif key == " try_install " :
# we make a separate package manager call for each package so a single
# we make a separate package manager call for each package so a single
# failing package won't stop all of them
# failing package won't stop all of them