{"id":18467927,"url":"https://github.com/ppvg/node-engine-check","last_synced_at":"2025-10-31T09:31:38.637Z","repository":{"id":57225334,"uuid":"52599134","full_name":"ppvg/node-engine-check","owner":"ppvg","description":"Enforce node engine version from package.json","archived":false,"fork":false,"pushed_at":"2017-12-05T17:50:48.000Z","size":5,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-25T18:34:14.849Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":false,"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/ppvg.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2016-02-26T11:09:06.000Z","updated_at":"2016-11-11T09:11:08.000Z","dependencies_parsed_at":"2022-08-24T11:00:15.273Z","dependency_job_id":null,"html_url":"https://github.com/ppvg/node-engine-check","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ppvg%2Fnode-engine-check","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ppvg%2Fnode-engine-check/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ppvg%2Fnode-engine-check/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ppvg%2Fnode-engine-check/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ppvg","download_url":"https://codeload.github.com/ppvg/node-engine-check/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239172384,"owners_count":19594137,"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":[],"created_at":"2024-11-06T10:04:00.641Z","updated_at":"2025-10-31T09:31:38.275Z","avatar_url":"https://github.com/ppvg.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Node engine check\n\nThis is a drop-in module to enforce the node engine version specified in your\nproject's package.json.\n\n## Usage\n\nAdd an [\"engines\" section](https://docs.npmjs.com/files/package.json#engines)\nto your `package.json`, if you don't have it already.\n\n```json\n{\n  \"name\": \"my-app\",\n  ...\n  \"engines\": {\n    \"node\": \"\u003e=4.0\"\n  }\n}\n```\n\nAdd this to the entry point of your node app:\n\n```javascript\n// index.js\nrequire('engine-check')()\nconsole.log('Hello node \u003e=4.0!')\n```\n\nAnd then run your app with the correct version of node:\n\n```text\nbash$ node -v\nv4.3.1\n\nbash$ node index.js\nHello node \u003e=4.0!\n\nbash$ echo $?\n0\n```\n\nOr with an outdated one:\n\n```text\nbash$ node -v\nv0.12.10\n\nbash$ node index.js\nDetected node version: 0.12.10. Required node version: \u003e=4.0.\n\nbash$ echo $?\n1\n```\n\nNote: the warning is sent to STDERR. If you'd rather not have any output, you\ncan set the `silent` option:\n\n```javascript\n// index.js\nrequire('engine-check')({ silent: true })\nconsole.log('Hello node \u003e=4.0!')\n```\n\n```text\nbash$ node -v\nv0.12.10\n\nbash$ node index.js\n\nbash$ echo $?\n1\n```\n\n\n### Available options\n\n- **`silent`** (default: `false`)\n  - when `true`, completely disables all STDERR output\n- **`debug`** (default: `false`)\n  - when `true`, STDERR output becomes more verbose\n- **`searchRoot`** (default: the dirname of the main module)\n  - where to start searching for the project's `package.json`\n  - **use with caution**\n\n## Caveats\n\nCurrently only the `\"node\"` engine is checked.\n\n## License\n\nCopyright (c) 2016, Peter-Paul van Gemerden.\nDistributed under the ISC license (see the `LICENSE` file).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fppvg%2Fnode-engine-check","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fppvg%2Fnode-engine-check","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fppvg%2Fnode-engine-check/lists"}