# cronerbly

> David Halewood - learnerbly exercise

Latest version **1.0.0** (published 2021-03-28) · ISC license · 0 weekly downloads

## Install

```sh
npm install cronerbly
pnpm add cronerbly
yarn add cronerbly
bun add cronerbly
```

Provides the command `cronerbly`.

## 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.0 |
| Published | 2021-03-28 |
| First published | 2021-03-28 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 11.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | David Halewood |
| Maintainers | cazoo-gitlab |

## Links

- npm: https://www.npmjs.com/package/cronerbly
- npm.io page: https://npm.io/package/cronerbly

## Dependencies (2)

- [ts-node](https://npm.io/package/ts-node.md) ^9.1.1
- [typescript](https://npm.io/package/typescript.md) ^4.2.3

## Recent versions

- 1.0.0 (latest) — 2021-03-28

## README

Cronerbly
===========
Learnerbly Coding Exercise


#### The Spec
We have a set of tasks, each running at least daily, which are scheduled using some simple
values in a text file. You might recognise this if you have written a crontab configuration in the
past.  

Examples of the the scheduler config:
* `30 1 /bin/run_me_daily`
* `45 * /bin/run_me_hourly`
* `* * /bin/run_me_every_minute`
* `19 /bin/run_me_sixty_times`  

The first field is the minute past the hour, the second field is the hour of the day and the third is
the command to run. For both cases `*` means that it should run for all values of that field. In the
above example, `run_me_daily` has been set to run at 1:30 am every day and `run_me_hourly` at
45 minutes past the hour every hour. The fields are whitespace-separated and each entry is on
a separate line.

We want you to write a command-line program that takes a single argument. This argument is
the simulated 'current time' in the format `HH:MM`. The program should accept config lines in the
form above to STDIN and output the soonest time at which each of the commands will fire and
whether it is today or tomorrow. In the case when the task should fire at the simulated 'current
time' then that is the time you should output, not the next one.  

For example given the above examples as input and the simulated 'current time' command-line
argument 16:10 the output should be:

* `1:30 tomorrow - /bin/run_me_daily`
* `16:45 today - /bin/run_me_hourly`
* `16:10 today - /bin/run_me_every_minute`
* `19:00 today - /bin/run_me_sixty_times`


#### Connect with me
* [github][github]
* [email][email]
* [website][website]


[github]: https://github.com/haletothewood
[website]: http://www.craftercoder.com
[email]: mailto:davidnhalewood@hotmail.com

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