5 module Puppet::Parser::Functions
6 newfunction(:shell_split, :type => :rvalue, :doc => <<-DOC
8 Splits a string into an array of tokens in the same way the Bourne shell does.
13 This function behaves the same as ruby's Shellwords.shellsplit() function
17 raise(Puppet::ParseError, "shell_split(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size != 1
19 string = arguments[0].to_s
21 result = Shellwords.shellsplit(string)
27 # vim: set ts=2 sw=2 et :