1
0
Fork 0
mirror of https://code.forgejo.org/actions/setup-python synced 2025-06-09 21:02:19 +02:00

initial commit (#938)

This commit is contained in:
priya-kinthali 2024-09-06 22:10:29 +05:30 committed by GitHub
parent f677139bbe
commit 29a37be0a3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 11 additions and 6 deletions

View file

@ -224,7 +224,10 @@ function extractValue(obj: any, keys: string[]): string | undefined {
export function getVersionInputFromTomlFile(versionFile: string): string[] {
core.debug(`Trying to resolve version form ${versionFile}`);
const pyprojectFile = fs.readFileSync(versionFile, 'utf8');
let pyprojectFile = fs.readFileSync(versionFile, 'utf8');
// Normalize the line endings in the pyprojectFile
pyprojectFile = pyprojectFile.replace(/\r\n/g, '\n');
const pyprojectConfig = toml.parse(pyprojectFile);
let keys = [];