fix: fix the matchers path for python

This commit is contained in:
Amin Yahyaabadi 2021-11-21 16:45:35 -06:00
parent bd2585f331
commit 991ce56d70
4 changed files with 23 additions and 5 deletions

18
.github/python.json vendored Normal file
View File

@ -0,0 +1,18 @@
{
"problemMatcher": [
{
"owner": "python",
"pattern": [
{
"regexp": "^\\s*File\\s\\\"(.*)\\\",\\sline\\s(\\d+),\\sin\\s(.*)$",
"file": 1,
"line": 2
},
{
"regexp": "^\\s*raise\\s(.*)\\(\\'(.*)\\'\\)$",
"message": 2
}
]
}
]
}

2
dist/setup_cpp.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,7 +1,7 @@
import * as core from "@actions/core" import * as core from "@actions/core"
import * as finder from "./setup-python/src/find-python" import * as finder from "./setup-python/src/find-python"
import * as finderPyPy from "./setup-python/src/find-pypy" import * as finderPyPy from "./setup-python/src/find-pypy"
import * as path from "path" // import * as path from "path"
function isPyPyVersion(versionSpec: string) { function isPyPyVersion(versionSpec: string) {
return versionSpec.startsWith("pypy-") return versionSpec.startsWith("pypy-")
@ -17,7 +17,7 @@ export async function setupActionsPython(version: string, _setupDir: string, arc
const installed = await finder.findPythonVersion(version, arch) const installed = await finder.findPythonVersion(version, arch)
core.info(`Successfully setup ${installed.impl} (${installed.version})`) core.info(`Successfully setup ${installed.impl} (${installed.version})`)
} }
const matchersPath = path.join("setup-pthon", ".github") // fails
core.info(`##[add-matcher]${path.join(matchersPath, "python.json")}`) // core.info(`##[add-matcher]${path.join("./.github", "python.json")}`)
return undefined return undefined
} }