UNPKG
ts-dev
Version:
latest (2.1.16)
2.1.16
2.1.15
Typescript development tools
gitlab.com/sosoba/ts-dev
ts-dev
/
dist
/
esm
/
program.js
18 lines
•
380 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
export
class
ProgamExit
extends
Error
{ }
export
const
main
=
async
(
cb
) => {
try
{
await
cb
(); }
catch
(e) {
if
(e
instanceof
ProgamExit
) {
if
(process.
exitCode
===
0
) { process.
exitCode
=
1
; } }
else
{
throw
e; } } };
//# sourceMappingURL=program.js.map