{"id":15290283,"url":"https://github.com/npm/read","last_synced_at":"2025-05-14T06:12:07.509Z","repository":{"id":1995897,"uuid":"2928893","full_name":"npm/read","owner":"npm","description":"read(1) for node.","archived":false,"fork":false,"pushed_at":"2025-04-09T21:59:25.000Z","size":144,"stargazers_count":196,"open_issues_count":12,"forks_count":34,"subscribers_count":19,"default_branch":"main","last_synced_at":"2025-05-07T09:50:57.919Z","etag":null,"topics":["npm-cli"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"isc","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/npm.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2011-12-06T23:23:36.000Z","updated_at":"2025-04-09T21:59:28.000Z","dependencies_parsed_at":"2023-07-05T18:17:53.221Z","dependency_job_id":"a41a932c-ac87-4b9e-bb0f-78e875e2ffac","html_url":"https://github.com/npm/read","commit_stats":{"total_commits":69,"total_committers":10,"mean_commits":6.9,"dds":"0.33333333333333337","last_synced_commit":"7a02d57fa65212bf82c2a7e1d7bb517239e35cf6"},"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/npm%2Fread","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/npm%2Fread/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/npm%2Fread/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/npm%2Fread/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/npm","download_url":"https://codeload.github.com/npm/read/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253253105,"owners_count":21878846,"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-cli"],"created_at":"2024-09-30T16:06:45.324Z","updated_at":"2025-05-14T06:12:07.386Z","avatar_url":"https://github.com/npm.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## read\n\nFor reading user input from stdin.\n\nSimilar to the `readline` builtin's `question()` method, but with a\nfew more features.\n\n## Usage\n\n```javascript\nconst { read } = require('read')\n// or with ESM: import { read } from 'read'\ntry {\n  const result = await read(options)\n} catch (er) {\n  console.error(er)\n}\n```\n\n## Options\n\nEvery option is optional.\n\n* `prompt` What to write to stdout before reading input.\n* `silent` Don't echo the output as the user types it.\n* `replace` Replace silenced characters with the supplied character value.\n* `timeout` Number of ms to wait for user input before giving up.\n* `default` The default value if the user enters nothing.\n* `edit` Allow the user to edit the default value.\n* `terminal` Treat the output as a TTY, whether it is or not.\n* `input` Readable stream to get input data from. (default `process.stdin`)\n* `output` Writable stream to write prompts to. (default: `process.stdout`)\n* `completer` Autocomplete callback (see [official api](https://nodejs.org/api/readline.html#readline_readline_createinterface_options) for details\n* `history` History array, which will be appended to.\n\nIf silent is true, and the input is a TTY, then read will set raw\nmode, and read character by character.\n\n## Contributing\n\nPatches welcome.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnpm%2Fread","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnpm%2Fread","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnpm%2Fread/lists"}