mirror of
https://github.com/actions/setup-java.git
synced 2025-07-23 15:08:26 +02:00
rebuild
This commit is contained in:
parent
a2ae8283cb
commit
10d2aa6bfd
2 changed files with 10 additions and 4 deletions
|
@ -100,8 +100,10 @@ export function isCacheFeatureAvailable(): boolean {
|
|||
return true;
|
||||
}
|
||||
|
||||
|
||||
export function getVersionFromFileContent(content: string, distributionName: string): string | null {
|
||||
export function getVersionFromFileContent(
|
||||
content: string,
|
||||
distributionName: string
|
||||
): string | null {
|
||||
const javaVersionRegExp = /(?<version>(?<=(^|\s|\-))(\d+\S*))(\s|$)/;
|
||||
const fileContent = content.match(javaVersionRegExp)?.groups?.version
|
||||
? (content.match(javaVersionRegExp)?.groups?.version as string)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue