{"id":22828693,"url":"https://github.com/busterc/readfile-split","last_synced_at":"2025-03-31T01:17:55.057Z","repository":{"id":57348675,"uuid":"41940054","full_name":"busterc/readfile-split","owner":"busterc","description":":heavy_division_sign: Read a file, splitting it's contents into an Array (for Node)","archived":false,"fork":false,"pushed_at":"2018-08-25T21:43:51.000Z","size":7,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-07T16:48:42.981Z","etag":null,"topics":["filesystem","fs","readfile"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/busterc.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":"2015-09-04T22:14:18.000Z","updated_at":"2023-09-08T17:01:21.000Z","dependencies_parsed_at":"2022-09-02T13:22:35.403Z","dependency_job_id":null,"html_url":"https://github.com/busterc/readfile-split","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/busterc%2Freadfile-split","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/busterc%2Freadfile-split/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/busterc%2Freadfile-split/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/busterc%2Freadfile-split/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/busterc","download_url":"https://codeload.github.com/busterc/readfile-split/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246399803,"owners_count":20770909,"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":["filesystem","fs","readfile"],"created_at":"2024-12-12T19:11:36.999Z","updated_at":"2025-03-31T01:17:55.033Z","avatar_url":"https://github.com/busterc.png","language":"JavaScript","readme":"# readfile-split [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency Status][daviddm-image]][daviddm-url]\n\u003e Read a file into an array\n\n\n## Install\n\n```sh\n$ npm install --save readfile-split\n```\n\n## Usage\n\n```js\nvar readfileSplit = require('readfile-split');\n\n// readfileSplit(filename[, options], callback)\n\n// options with defaults\nvar options = {\n  // fs.readFile specific options\n  encoding: null,\n  flag: 'r',\n\n  // readfileSplit specific options\n  emptyLines: true,\n  trimLines: true,\n  withSeperator: false,\n  seperator: /\\r?\\n/\n};\n\nreadfileSplit('/somewhere/somefile', options, console.log);\n// \u003e null [ 'Hello,', '', 'Don\\'t worry.', 'Be happy.', '', 'Goodbye!', '' ]\n\noptions.emptyLines = false;\nreadfileSplit('/somewhere/somefile', options, console.log);\n// \u003e null [ 'Hello,', 'Don\\'t worry.', 'Be happy.', 'Goodbye!' ]\n\noptions.seperator = '.';\nreadfileSplit('/somewhere/somefile', options, console.log);\n// \u003e null [ 'Hello,\\n\\nDon\\'t worry', 'Be happy', 'Goodbye!' ]\n\noptions.withSeperator = true;\nreadfileSplit('/somewhere/somefile', options, console.log);\n// \u003e null [ 'Hello,\\n\\nDon\\'t worry.', 'Be happy.', 'Goodbye!' ]\n\n// etc.\n```\n\n## License\n\nISC © [Buster Collings](http://about.me/buster)\n\n\n[npm-image]: https://badge.fury.io/js/readfile-split.svg\n[npm-url]: https://npmjs.org/package/readfile-split\n[travis-image]: https://travis-ci.org/busterc/readfile-split.svg?branch=master\n[travis-url]: https://travis-ci.org/busterc/readfile-split\n[daviddm-image]: https://david-dm.org/busterc/readfile-split.svg?theme=shields.io\n[daviddm-url]: https://david-dm.org/busterc/readfile-split\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbusterc%2Freadfile-split","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbusterc%2Freadfile-split","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbusterc%2Freadfile-split/lists"}