clock-helper

    1.0.0 • Public • Published

    clock-helper

    npm version

    A clock helper for querying the time of startup and shutdown

    Installation

    $ npm install clock-helper

    Usage

    const { getShutdownDateList } = require('clock-helper');
     
    (async () => {
      try {
        const osShutdownDateList = await getShutdownDateList();
        console.log(osShutdownDateList));
        // [ 2019-08-24T13:58:43.968Z,
        // 2019-08-24T04:51:14.941Z,
        // 2019-08-22T15:16:36.939Z,
        // 2019-08-21T15:43:08.332Z,
        // 2019-08-18T15:35:03.466Z ]
      } catch(err) {
        console.error(err);
      }
    })();

    API

    • getStartupDateList()
    • getShutdownDateList()

    TODO

    • Support for macOS/Linux
    • CLI
    • Add unit test cases

    License

    MIT © Qingrong Ke

    References

    Install

    npm i clock-helper

    DownloadsWeekly Downloads

    0

    Version

    1.0.0

    License

    MIT

    Unpacked Size

    14.8 kB

    Total Files

    13

    Last publish

    Collaborators

    • dearke