Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cyco130/who-said-that
Adds a prefix that identifies the currently running npm script to every line of its output
https://github.com/cyco130/who-said-that
Last synced: about 2 months ago
JSON representation
Adds a prefix that identifies the currently running npm script to every line of its output
- Host: GitHub
- URL: https://github.com/cyco130/who-said-that
- Owner: cyco130
- License: mit
- Created: 2021-09-25T19:54:09.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-09-25T21:15:23.000Z (over 3 years ago)
- Last Synced: 2024-05-08T00:15:22.734Z (8 months ago)
- Language: TypeScript
- Homepage:
- Size: 16.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Who said that?!
Adds a prefix that identifies the currently running npm script to every line of its output.
## Why?
Sometimes it's hard to identify which line of output comes from which script when running multiple npm scripts in parallel or in series like in a monorepo build or a continuous integration output. Just prefix your npm script definition with `who-said-that` and you will have a tag that includes the package name and the script name on every output line.## How?
Given that you have an npm script like this:```json
"lint": "who-said-that eslint"
```You will have an output like this:
[your-package lint]: /path/to/your/file.js
[your-package lint]: 7:40 warning 'x' is defined but never usedAnd it will help you identify which package (`your-package`) and which script (`lint`) logged these messages when examining a large log, for instance.
## Installation
```sh
npm install --save-dev who-said-that
```Or you can install it globally if you like:
```sh
npm install -g who-said-that
```## Credits
- [Fatih Aygün](https://github.com/cyco130), [MIT License](https://opensource.org/licenses/MIT).