Examples of zpm files?

Hi @njfranck - I just put some lines together to give you an impression on how a szpm file looks like. There is no magic involved:

{
  "name": "Addon",
  "version": "1.0.0",
  "vendor": "Zammad GmbH",
  "license": "GNU AGPL v2",
  "url": "http://zammad.org/",
  "change_log": [
    {
      "version": "1.0.0",
      "date": "2019-08-05 13:37:42 UTC",
      "log": "Initial version."
    }
  ],
  "description": [
    {
      "language": "en",
      "text": "Adding custom functionality XY."
    }
  ],
  "files": [
    {
      "location": "app/model/custom.rb",
      "permission": 644
    }
  ]
}

To get a installable zpm file from this you have to encode the files content via base64 and add it to the corresponding record and add the "encode": "base64", attribute, too. Additionally the buildhost and builddate attributes should get set. The final zpm file would look like this:

{
  "name": "Addon",
  "version": "1.0.0",
  "vendor": "Zammad GmbH",
  "license": "GNU AGPL v2",
  "url": "http://zammad.org/",
  "buildhost": "build.zammad.com",
  "builddate": "2019-08-05 13:37:42 UTC",
  "change_log": [
    {
      "version": "1.0.0",
      "date": "2019-08-05 13:37:23 UTC",
      "log": "Initial version."
    }
  ],
  "description": [
    {
      "language": "en",
      "text": "Adding custom functionality XY."
    }
  ],
  "files": [
    {
      "location": "app/model/custom.rb",
      "permission": 644,
      "encode": "base64",
      "content": "cHV0cyAiSGVsbG8gdGhlcmUgOikgRHJvcCB1cyBhIG1haWwgYXQgam9ic0B6YW1tYWQuY29tIC0gd2UnZCBsaWtlIHRvIHRhbGsgdG8geW91IPCfpbAi"
    }
  ]
}

There is an undocumented gem which does some szpm/zpm handling. We’re using it in our build system.

However, we won’t put much more effort in the szpm/zpm eco system because we will replace the whole packaging mechanism in the future. However, since we have quite a few customer and internal packages we will provide a straight forward migration mechanism / documentation when the time comes. So your work wont be lost if you decide to create a zpm file.

Let me know if I can help you any further.

PS: What are you building? :slight_smile: