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.
24 lines
555 B
24 lines
555 B
import { run } from '@jupyterlab/buildutils';
|
|
|
|
/**
|
|
* Get the current version of RetroLab
|
|
*/
|
|
export function getPythonVersion(): string {
|
|
const cmd = 'python setup.py --version';
|
|
const lines = run(cmd, { stdio: 'pipe' }, true).split('\n');
|
|
return lines[lines.length - 1];
|
|
}
|
|
|
|
export function postbump(commit = true): void {
|
|
// run the integrity
|
|
run('jlpm integrity');
|
|
|
|
const newPyVersion = getPythonVersion();
|
|
|
|
// Commit changes.
|
|
if (commit) {
|
|
run(`git commit -am "Release ${newPyVersion}"`);
|
|
run(`git tag ${newPyVersion}`);
|
|
}
|
|
}
|