actions-hugo/src/index.ts
yutopp 54af4c1320
fix: Wrap an entrypoint by async to handle exceptions correctly (#363)
* fix: add return type

Co-authored-by: Shohei Ueda <30958501+peaceiris@users.noreply.github.com>
2020-06-21 13:16:10 +09:00

11 lines
219 B
TypeScript

import * as core from '@actions/core';
import * as main from './main';
(async (): Promise<void> => {
try {
await main.run();
} catch (e) {
core.setFailed(`Action failed with error ${e.message}`);
}
})();