Code Review
/
puppet-modules
/
puppetlabs-apt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Merge pull request #332 from zacharyalexstern/fix_readme_typo
[puppet-modules/puppetlabs-apt.git]
/
manifests
/
pin.pp
diff --git
a/manifests/pin.pp
b/manifests/pin.pp
index 2563fc468176d8c62844654a435c5f0eb7ec7de1..2ce81fd6bb292fce2eae61e60bf82b2e01bfa048 100644
(file)
--- a/
manifests/pin.pp
+++ b/
manifests/pin.pp
@@
-64,10
+64,6
@@
define apt::pin(
}
}
- $path = $order ? {
- '' => "${preferences_d}/${name}.pref",
- default => "${preferences_d}/${order}-${name}.pref",
- }
# According to man 5 apt_preferences:
# The files have either no or "pref" as filename extension
# According to man 5 apt_preferences:
# The files have either no or "pref" as filename extension
@@
-78,6
+74,10
@@
define apt::pin(
# be silently ignored.
$file_name = regsubst($title, '[^0-9a-z\-_\.]', '_', 'IG')
# be silently ignored.
$file_name = regsubst($title, '[^0-9a-z\-_\.]', '_', 'IG')
+ $path = $order ? {
+ '' => "${preferences_d}/${file_name}.pref",
+ default => "${preferences_d}/${order}-${file_name}.pref",
+ }
file { "${file_name}.pref":
ensure => $ensure,
path => $path,
file { "${file_name}.pref":
ensure => $ensure,
path => $path,