You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
abp/npm/get-version.js

11 lines
337 B

const fse = require('fs-extra');
const commonProps = fse.readFileSync('../common.props').toString();
const versionTag = '<Version>';
const versionEndTag = '</Version>';
const first = commonProps.indexOf(versionTag) + versionTag.length;
const last = commonProps.indexOf(versionEndTag);
console.log(commonProps.substring(first, last));