/
krisfloop
/
notebook
Обзор
Документация
Войти
/
krisfloop
/
notebook
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
buildutils/src/utils.ts
23 строки
543 B
Steven Silvester
switch to hatch for python version
23 сен 2022, 20:10
23 сен 2022, 20:10
697ba0f
Код
Авторство
О чём код?
import { run } from '@jupyterlab/buildutils'; /** * Get the current version of notebook */ export function getPythonVersion(): string { const cmd = 'hatch 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}`); } }