forked from redhat-openstack/openstack-puppet-modules
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MODULES-1759: Remove dependency on stdlib >=4.1.0
Backported dirname => mysql_dirname since updating dependency to stdlib 4.1.0 is backwards incompatible with some versions of PE.
- Loading branch information
Morgan Haskel
committed
Feb 9, 2015
1 parent
b57191f
commit 96f4d16
Showing
3 changed files
with
17 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
module Puppet::Parser::Functions | ||
newfunction(:mysql_dirname, :type => :rvalue, :doc => <<-EOS | ||
Returns the dirname of a path. | ||
EOS | ||
) do |arguments| | ||
|
||
raise(Puppet::ParseError, "mysql_dirname(): Wrong number of arguments " + | ||
"given (#{arguments.size} for 1)") if arguments.size < 1 | ||
|
||
path = arguments[0] | ||
return File.dirname(path) | ||
end | ||
end | ||
|
||
# vim: set ts=2 sw=2 et : |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters