зеркало из https://github.com/Azure/cli.git
Added entrypoint.ts
This commit is contained in:
Родитель
f032865981
Коммит
fa0f960f00
|
@ -24,7 +24,7 @@ jobs:
|
|||
|
||||
- name: Compile files
|
||||
run: |
|
||||
ncc build -C -m src/main.ts
|
||||
ncc build -C -m src/entrypoint.ts
|
||||
|
||||
- name: Commit Files
|
||||
continue-on-error: true # commit will fail if the code wasn't changed. Prevent the build to fail in this case.
|
||||
|
|
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
|
@ -2,7 +2,7 @@
|
|||
"name": "cli",
|
||||
"version": "1.0.7",
|
||||
"description": "Automate your GitHub workflows using Azure CLI scripts.",
|
||||
"main": "lib/main.js",
|
||||
"main": "src/main.js",
|
||||
"scripts": {
|
||||
"build": "tsc",
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
import { setFailed } from '@actions/core';
|
||||
import { main } from './main';
|
||||
|
||||
main()
|
||||
.then(() => {
|
||||
process.exit(0)
|
||||
})
|
||||
.catch((err: Error) => {
|
||||
setFailed(err.message);
|
||||
process.exit(1);
|
||||
});
|
|
@ -154,5 +154,3 @@ const executeDockerCommand = async (dockerCommand: string, continueOnError: bool
|
|||
core.warning(errorStream)
|
||||
}
|
||||
}
|
||||
|
||||
main()
|
||||
|
|
|
@ -4,7 +4,7 @@ import * as core from '@actions/core';
|
|||
// Unit Tests
|
||||
export async function runTests() {
|
||||
try {
|
||||
let result = await main()
|
||||
await main()
|
||||
return 'pass'
|
||||
} catch (e) {
|
||||
core.error(JSON.stringify(e))
|
||||
|
|
Загрузка…
Ссылка в новой задаче