Metadata

The metadata attribute of the manifest front matter is a place to store information about the manifest.

Ideally, it should be specified after the manifest version.

There is only 1 required item and that is the gene_system object. This is used for genesystem to determine the whether it is capable of installing the manifest on the current host system. Right now, that’s simply a version check (which means the version attribute must be present in the gene_system object), to ensure that the manifest does not come from a newer version of the gem.

This is an example of the metadata object:

{
  "name": "example",
  "version": "1.0.0",
  "metadata": {
    "gene_system": {
      "version": "0.4.0"
    }
  }
  # ... remainder of manifest goes here
}

You may add additional metadata into this block that assists you in describing the manifest to other systems that may consume it.

Access to manifest metadata in command variables

You can access metadata from commands if you required like this:

{
  "name": "manifest",
  "version": "0.0.1",
  "metadata": {
    "gene_system": {
      "version": "0.4.0"
    }
  },
  "steps": [
    {
      "name": "print manifest gene_system version",
      "exe": {
        "install": {
          "cmd": [
            "echo \"{{manifest.metadata.gene_system.version}}\""
          ]
        },
      },
      "tags": "example step"
    }
  ]
}

You may want to do this if information about the manifest is useful in a bash command.

It is recommended though that you do not put any information that does not assist in describing a manifest within this block though as it might affect future functionality with the metadata block.