aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Backlund <tmb@mageia.org>2015-10-20 09:46:55 +0300
committerThomas Backlund <tmb@mageia.org>2015-10-20 09:46:55 +0300
commitfa7d4cff7dbaf8e808a28f4e00b1d656bdf45684 (patch)
tree6e5ea2d901a24059d2c30a3a2f5742cb89536d54
parent23395242055e0ebc067e83edcaf09d67ef2e2497 (diff)
downloadpuppet-fa7d4cff7dbaf8e808a28f4e00b1d656bdf45684.tar
puppet-fa7d4cff7dbaf8e808a28f4e00b1d656bdf45684.tar.gz
puppet-fa7d4cff7dbaf8e808a28f4e00b1d656bdf45684.tar.bz2
puppet-fa7d4cff7dbaf8e808a28f4e00b1d656bdf45684.tar.xz
puppet-fa7d4cff7dbaf8e808a28f4e00b1d656bdf45684.zip
lint fixes for mga_common
-rw-r--r--modules/mga_common/lib/puppet/parser/functions/group_members.rb2
-rw-r--r--modules/mga_common/lib/puppet/parser/functions/str_join.rb2
-rw-r--r--modules/mga_common/manifests/local_script.pp26
3 files changed, 15 insertions, 15 deletions
diff --git a/modules/mga_common/lib/puppet/parser/functions/group_members.rb b/modules/mga_common/lib/puppet/parser/functions/group_members.rb
index c5cecbe8..0324adb2 100644
--- a/modules/mga_common/lib/puppet/parser/functions/group_members.rb
+++ b/modules/mga_common/lib/puppet/parser/functions/group_members.rb
@@ -3,7 +3,7 @@ require 'etc'
# -> return a array with the login of the group members
module Puppet::Parser::Functions
- newfunction(:group_members, :type => :rvalue) do |args|
+ newfunction(:group_members, :type => :rvalue) do |args|
group = args[0]
return Etc.getgrnam(group).mem
end
diff --git a/modules/mga_common/lib/puppet/parser/functions/str_join.rb b/modules/mga_common/lib/puppet/parser/functions/str_join.rb
index de97bfb5..c881c37d 100644
--- a/modules/mga_common/lib/puppet/parser/functions/str_join.rb
+++ b/modules/mga_common/lib/puppet/parser/functions/str_join.rb
@@ -3,7 +3,7 @@
# a string, separated by $sep
module Puppet::Parser::Functions
- newfunction(:str_join, :type => :rvalue) do |args|
+ newfunction(:str_join, :type => :rvalue) do |args|
array = args[0]
sep = args[1]
return array.join(sep)
diff --git a/modules/mga_common/manifests/local_script.pp b/modules/mga_common/manifests/local_script.pp
index 70aad7b0..3272786b 100644
--- a/modules/mga_common/manifests/local_script.pp
+++ b/modules/mga_common/manifests/local_script.pp
@@ -1,22 +1,22 @@
define mga_common::local_script(
$content = undef,
$source = undef,
- $owner = 'root',
- $group = 'root',
- $mode = '0755') {
- $filename = "/usr/local/bin/$name"
+ $owner = 'root',
+ $group = 'root',
+ $mode = '0755') {
+ $filename = "/usr/local/bin/${name}"
file { $filename:
- owner => $owner,
- group => $group,
- mode => $mode,
+ owner => $owner,
+ group => $group,
+ mode => $mode,
}
if ($source == undef) {
- File[$filename] {
- content => $content,
- }
+ File[$filename] {
+ content => $content,
+ }
} else {
- File[$filename] {
- source => $source,
- }
+ File[$filename] {
+ source => $source,
+ }
}
}