{"id":13583728,"url":"https://github.com/stefanmaric/ntee","last_synced_at":"2025-08-01T13:36:47.088Z","repository":{"id":65369956,"uuid":"37563734","full_name":"stefanmaric/ntee","owner":"stefanmaric","description":"Portable Unix shell command 'tee', with some extras - read from standard input and write to standard output and files","archived":false,"fork":false,"pushed_at":"2019-05-25T23:06:16.000Z","size":13,"stargazers_count":23,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-15T16:25:38.998Z","etag":null,"topics":["npm","npm-scripts","ntee","pipe","shell","stdin","stdout","tee"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/ntee","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stefanmaric.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-06-17T00:40:23.000Z","updated_at":"2022-04-20T08:50:49.000Z","dependencies_parsed_at":"2023-01-19T23:16:26.700Z","dependency_job_id":null,"html_url":"https://github.com/stefanmaric/ntee","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stefanmaric%2Fntee","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stefanmaric%2Fntee/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stefanmaric%2Fntee/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stefanmaric%2Fntee/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stefanmaric","download_url":"https://codeload.github.com/stefanmaric/ntee/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250372073,"owners_count":21419715,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["npm","npm-scripts","ntee","pipe","shell","stdin","stdout","tee"],"created_at":"2024-08-01T15:03:44.185Z","updated_at":"2025-04-23T04:33:11.530Z","avatar_url":"https://github.com/stefanmaric.png","language":"JavaScript","readme":"# ntee\n\nPortable Unix shell command `tee`, with some extras — read from standard input and write to standard output and files.\n\n## TL;DR\n\n`gulp.dest()` in middle of a pipe? NPM scripts can do as well:\n\n```json\n{\n  \"scripts\": {\n    \"less\": \"lessc main.less | postcss --use autoprefixer | ntee main.css | cleancss \u003e main.min.css\"\n  }\n}\n```\n\n## Install\n\n```shell\n$ npm install -g ntee\n```\n\n## Check\n\n```shell\n$ ntee --help\n```\n\n## Use\n\n```\nUsage:\n  ntee [OPTION]... FILE...\n\n  Copy standard input to each FILE, and also to standard output.\n\nOptions:\n  -a, --append              append to the given FILEs, do not overwrite\n  -i, --ignore-interrupts   ignore interrupt signals\n  -s, --suppress            do not output to stdout\n  -v, --version             display the current version\n  -h, --help                display help and usage details\n```\n\n```shell\n$ whoami | ntee file1.txt file2.txt\n```\n\nWill print current user to stdout and also to `file1.txt` and `file2.txt`. Note that if these files already exist, they will be overwritten. Use `-a`/`--append` to avoid it, just like you would do with Richard Stallman's `tee`:\n\n```shell\n$ whoami | ntee -a i-wont-be-overwritten.txt\n```\n\n`-i`/`--ignore-interrupts` will prevent \u003ckbd\u003eCTRL\u003c/kbd\u003e+\u003ckbd\u003eC\u003c/kbd\u003e from killing `ntee`. Won't work on windows.\n\nI also added an `-s`/`--suppress` option to suppress output to stdout. This meant to be used on npm scripts:\n\n```shell\n$ echo \"Nothing will be shown in screen\" | ntee -s but-it-will-be-saved-here.txt\n```\n\nYou can always pipe:\n\n```shell\ncat long.log | sort | ntee sorted.log | head\n```\n\n## License\n\n[MIT](./LICENSE.md) ♥\n","funding_links":[],"categories":["JavaScript","Cross-platform Utilities"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstefanmaric%2Fntee","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstefanmaric%2Fntee","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstefanmaric%2Fntee/lists"}