Sha256: f9669a600988f710dd81d749b41340f84999ff837a80cadd02f7666b9973a6fe

Contents?: true

Size: 457 Bytes

Versions: 3

Compression:

Stored size: 457 Bytes

Contents

# frozen_string_literal: true

$LOAD_PATH.unshift File.expand_path("../lib", __dir__)
require "awesome_print"
require "archivesspace/client"

puts ArchivesSpace::Template.list

template = "repository_with_agent.json.erb"
user_data = {
  username: "harrykane",
  name: "Harry Kane",
  is_admin: false
}

puts ArchivesSpace::Template.process(template, user_data)
# or, if you really want ...
puts ArchivesSpace::Template::Erb.new(template, user_data).process

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
archivesspace-client-0.4.1 examples/templates.rb
archivesspace-client-0.4.0 examples/templates.rb
archivesspace-client-0.3.0 examples/templates.rb