Add Apps-Engine to Engine Versions on History (#17810)

pull/16332/head^2
Douglas Gubert 5 years ago committed by GitHub
parent 68d25770cd
commit 62a7ffc242
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 18
      .houston/metadata.js
  2. 3
      .houston/templates/versions.hbs

@ -36,8 +36,24 @@ const getNodeNpmVersions = async function({ version, git, request }) {
return {};
};
const getAppsEngineVersion = async function({ version, git }) {
try {
const packageJson = await git.show([`${ version }:package-lock.json`]);
const { dependencies } = JSON.parse(packageJson);
const { version: appsEngineVersion } = dependencies['@rocket.chat/apps-engine'];
return appsEngineVersion;
} catch (e) {
console.error(e);
}
return undefined;
};
module.exports = async function({ version, git, request }) {
const mongo_versions = await getMongoVersion({ version, git });
const apps_engine_version = await getAppsEngineVersion({ version, git });
const {
node_version,
npm_version,
@ -46,6 +62,8 @@ module.exports = async function({ version, git, request }) {
return {
node_version,
npm_version,
apps_engine_version,
mongo_versions,
};
};

@ -10,4 +10,7 @@
{{#if release.mongo_versions}}
- MongoDB: `{{ join release.mongo_versions ', ' }}`
{{/if}}
{{#if release.apps_engine_version}}
- Apps-Engine: `{{ release.apps_engine_version }}`
{{/if}}
{{/if}}

Loading…
Cancel
Save