# recursive-last-modified

> Walks through specified directory or directories and returns last change date of all tree. Tecnically it is the newest modified or created date of all files in specified dir

Latest version **1.0.6** (published 2022-03-30) · MIT license · 0 weekly downloads

## Install

```sh
npm install recursive-last-modified
pnpm add recursive-last-modified
yarn add recursive-last-modified
bun add recursive-last-modified
```

## 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.6 |
| Published | 2022-03-30 |
| First published | 2018-04-12 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 4.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 5 |
| Author | Mikhail Busyrev |
| Maintainers | aquahawk |
| Keywords | last-modified, recursive, folder, directory |

## Links

- npm: https://www.npmjs.com/package/recursive-last-modified
- Repository: https://github.com/Busyrev/recursive-last-modified
- Homepage: https://github.com/Busyrev/recursive-last-modified#readme
- Issues: https://github.com/Busyrev/recursive-last-modified/issues
- npm.io page: https://npm.io/package/recursive-last-modified

## Recent versions

- 1.0.6 (latest) — 2022-03-30
- 1.0.5 — 2018-04-12
- 1.0.4 — 2018-04-12
- 1.0.3 — 2018-04-12
- 1.0.2 — 2018-04-12
- 1.0.1 — 2018-04-12
- 1.0.0 — 2018-04-12

## README

# recursive-last-modified
Walks through specified directory or directories and returns last change date of all tree. Technically it is the newest modified or created date of all files in specified dir

[Npm module](https://www.npmjs.com/package/recursive-last-modified)

Last modified date in this readme and code means newest date for each directory and file recursively from:

* [stats.birthtimeMs](https://nodejs.org/api/fs.html#fs_stats_birthtimems)
* [stats.ctimeMs](https://nodejs.org/api/fs.html#fs_stats_ctimems)
* [stats.mtimeMs](https://nodejs.org/api/fs.html#fs_stats_mtimems)


## Future plans
* node-glob syntax support  https://github.com/isaacs/node-glob
* excludes
* optional ability to skip missing paths. False by default? 
* ability to get list of files modified since specified date

## More details

You can specify not only directory, but file. And array of files and directories mixed. 

## Usage

```js
let rlm = require('recursive-last-modified');

console.log(rlm('.')) // prints last modified date of current folder and all its content

console.log(rlm(['dir1', 'dir2'])) // prints newest last modified date of dir1, dir2 and all content in them

console.log(rlm('path/to/some/file.txt')) // prints last modified date of path/to/some/file.txt
```

## Thanks

Development of the project was sponsored by [Crazy Panda](https://crazypanda.ru/)

## License
Licensed in terms of MIT license (see https://github.com/Busyrev/recursive-last-modified/blob/master/LICENSE file).

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