tools/generate-history
author Shawn Ferry <shawn.ferry@oracle.com>
Wed, 10 Feb 2016 22:10:43 -0500
changeset 5438 c068f8c677e8
parent 4813 5e86eaf216ff
child 5571 bd6c9b9b753f
child 7036 9bdfcd8747ba
permissions -rw-r--r--
PSARC/2016/016 Rename/Refactor Puppet and Puppet Module Packages 21041932 puppet, facter, and hiera need to build Ruby 2.1 packages 21042030 puppet, facter, and hiera need to stop building Ruby 1.9 packages 21613616 oracle-solaris_provider builds should come from the github repo we publish 22047789 puppet package name and dependencies are confusing 22301978 Overzealous use of $(RUBY_VERSION) in puppet packaging 22347610 GIT repos cannot be used as described in docs 22664785 Puppet module files should be owned by puppet 22675056 git clone could use --depth 1

# If invoked with -v FUNCTION=name, then just print $1 (s|/|---|).
# Otherwise we expect to be invoked with TARGET=<whatever>, then if
# s|/|---| on $1 matches TARGET, we generate a manifest.
{
  if (substr($1, 1, 1) == "#") { # Skip comments.
    continue
  }
  fmri=$1
  split(fmri, a, "@")
  gsub("/", "---", a[1])
  target = sprintf("%s.p5m", a[1])
  if (FUNCTION == "name") {
    printf "%s\n", target
    continue
  }
  if (target != TARGET) {
    continue
  }
  printf "set name=pkg.fmri value=pkg:/%s\n", fmri
  if (NF == 2) {
    print "set name=pkg.renamed value=true"
    printf "depend type=require fmri=%s\n", $2
  } else {
    print "set name=pkg.obsolete value=true"
  }
  print "set name=org.opensolaris.consolidation value=$(CONSOLIDATION)"
  exit 0 # We're done; no point continuing.
}