Sha256: b225da3713bace16f025814c0da2bde435bf953fca997e071e9d070c43775fba

Contents?: true

Size: 528 Bytes

Versions: 71

Compression:

Stored size: 528 Bytes

Contents

# frozen_string_literal: true

# Join file paths using ruby's `File.join()` function.
Puppet::Functions.create_function(:'file::join') do
  # @param paths The paths to join.
  # @return The joined file path.
  # @example Join file paths
  #   file::join('./path', 'to/files')
  dispatch :join do
    required_repeated_param 'String', :paths
    return_type 'String'
  end

  def join(*paths)
    # Send Analytics Report
    Puppet.lookup(:bolt_executor) {}&.report_function_call(self.class.name)

    File.join(paths)
  end
end

Version data entries

71 entries across 71 versions & 1 rubygems

Version Path
bolt-3.0.1 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-3.0.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.44.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.42.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.40.2 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.40.1 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.38.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.37.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.36.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.35.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.34.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.33.2 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.33.1 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.32.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.31.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.30.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.29.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.28.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.27.0 bolt-modules/file/lib/puppet/functions/file/join.rb
bolt-2.26.0 bolt-modules/file/lib/puppet/functions/file/join.rb