release/fillReleaseNotesTemplate.js
/**
 * Takes agent version as the first cmdline argument.
 * 
 * Reads the releaseNote.md template file content and replaces `<AGENT_VERSION>` and `<HASH>` with agent version and package hash respectively.
 */
Takes agent version as the first cmdline argument.

Reads the releaseNote.md template file content and replaces `` and `` with agent version and package hash respectively.
Takes agent version as the first cmdline argument . Reads the releaseNote . md template file content and replaces ` ` and ` ` with agent version and package hash respectively .
function main() {
    const agentVersion = process.argv[2];
    if (agentVersion === undefined) {
        throw new Error('Agent version argument must be supplied');
    }
    const releaseNotesPath = path.join(__dirname, '..', 'releaseNote.md');
    const releaseNotes = fs.readFileSync(releaseNotesPath, 'utf-8');
    const releaseNotesWithAgentVersion = addAgentVersionToReleaseNotes(releaseNotes, agentVersion);
    const filledReleaseNotes = addHashesToReleaseNotes(releaseNotesWithAgentVersion);
    fs.writeFileSync(releaseNotesPath, filledReleaseNotes);
}
function main ( ) { const agentVersion = process . argv [ 2 ] ; if ( agentVersion === undefined ) { throw new Error ( 'Agent version argument must be supplied' ) ; } const releaseNotesPath = path . join ( __dirname , '..' , 'releaseNote.md' ) ; const releaseNotes = fs . readFileSync ( releaseNotesPath , 'utf-8' ) ; const releaseNotesWithAgentVersion = addAgentVersionToReleaseNotes ( releaseNotes , agentVersion ) ; const filledReleaseNotes = addHashesToReleaseNotes ( releaseNotesWithAgentVersion ) ; fs . writeFileSync ( releaseNotesPath , filledReleaseNotes ) ; }
Takes agent version as the first cmdline argument.
Takes agent version as the first cmdline argument .