# @mangar2/shutdown

> Implements graceful shutdown

Latest version **1.0.3** (published 2020-12-10) · LGPL-3.0-or-later license · 0 weekly downloads

## Install

```sh
npm install @mangar2/shutdown
pnpm add @mangar2/shutdown
yarn add @mangar2/shutdown
bun add @mangar2/shutdown
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.3 |
| Published | 2020-12-10 |
| First published | 2019-09-28 |
| Weekly downloads | 0 |
| License | LGPL-3.0-or-later |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 3.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Volker Böhm |
| Maintainers | mangar2 |
| Keywords | graceful, shutdown, SIGINT, SIGTERM |

## Links

- npm: https://www.npmjs.com/package/@mangar2/shutdown
- Repository: https://github.com/Mangar2/yaha/tree/master/node_modules/@mangar2/shutdown
- Homepage: https://github.com/Mangar2/yaha.git
- npm.io page: https://npm.io/package/@mangar2/shutdown

## Recent versions

- 1.0.3 (latest) — 2020-12-10
- 1.0.2 — 2020-01-14
- 1.0.1 — 2019-10-15
- 1.0.0 — 2019-09-28

## README

<!-- This file is generated by jsmddoc version 0.1 -->

# Abstract

Shutdown is a small helper to safely shutdown serivces on SIGINT ( ctrl-C ) A singelton calling a callback on SIGINT and provides a timeout if the callback does not finish in a period of time .

Example

```shell
const shutdown = require('shutdown');

shutdown(async () => {
   await myClass.close();
   process.exit(0);
});
```

## Contents

- [Meta](#Meta)

## Meta

---
_Source: https://npm.io/package/@mangar2/shutdown · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
