Factorize.
This commit is contained in:
parent
4625afacae
commit
5846da98ce
1 changed files with 1 additions and 6 deletions
|
@ -1,12 +1,7 @@
|
|||
define apt::upgrade_package ($version = "") {
|
||||
|
||||
case $version {
|
||||
'': {
|
||||
exec { "aptitude -y install $name":
|
||||
onlyif => [ "grep-status -F Status installed -a -P $name -q", "apt-show-versions -u $name | grep -q upgradeable" ],
|
||||
}
|
||||
}
|
||||
'latest': {
|
||||
'', 'latest': {
|
||||
exec { "aptitude -y install $name":
|
||||
onlyif => [ "grep-status -F Status installed -a -P $name -q", "apt-show-versions -u $name | grep -q upgradeable" ],
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue