{"id":22909511,"url":"https://github.com/blueskyfish/endless-core","last_synced_at":"2026-04-30T00:09:14.306Z","repository":{"id":47576976,"uuid":"105359153","full_name":"blueskyfish/endless-core","owner":"blueskyfish","description":"A small demo how to read a text file endless","archived":false,"fork":false,"pushed_at":"2023-10-03T00:28:05.000Z","size":317,"stargazers_count":0,"open_issues_count":6,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-02-01T23:32:15.617Z","etag":null,"topics":["chokida","nodejs","readable","stream","tail","writable"],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/blueskyfish.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-09-30T09:29:40.000Z","updated_at":"2022-11-13T12:57:33.000Z","dependencies_parsed_at":"2025-02-08T15:30:31.908Z","dependency_job_id":null,"html_url":"https://github.com/blueskyfish/endless-core","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/blueskyfish/endless-core","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blueskyfish%2Fendless-core","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blueskyfish%2Fendless-core/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blueskyfish%2Fendless-core/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blueskyfish%2Fendless-core/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/blueskyfish","download_url":"https://codeload.github.com/blueskyfish/endless-core/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blueskyfish%2Fendless-core/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32448916,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T22:27:22.272Z","status":"ssl_error","status_checked_at":"2026-04-29T22:10:49.234Z","response_time":110,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["chokida","nodejs","readable","stream","tail","writable"],"created_at":"2024-12-14T03:39:15.967Z","updated_at":"2026-04-30T00:09:14.250Z","avatar_url":"https://github.com/blueskyfish.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n[![Endless Core](logo.png)](#logo)\n\n# Endless Core\n\n\u003e Watch file changes and delivery the file content like tail\n\n## Overview\n\n![Components](assets/components.png)\n\nThe **WatcherService** is the front to monitor file changes.\n\n```ts\n/*     */ import { IWatcherLiner, splitLines, WatcherService, WatcherObservable } from 'endless-core';\n/*     */\n/*     */ const watcherService: WatcherService = ...\n/*     */ const filename = ...\n/* (1) */ const watcher$: WatcherObservable = watcherService.add(filename, { encoding: 'utf8', fromPosition: 1024});\n/*     */\n/* (2) */ watcher$.start()\n/*     */  .pipe(\n/*     */    splitLines(),\n/*     */  )\n/*     */  .subscribe((line: IWatcherLiner) =\u003e {\n/*     */    console.log('%s: %s', line.index, line.text);\n/*     */   });\n/*     */\n/*     */\n/* (3) */ watcher$.close();\n```\n* (1) With \"add\" a **WatcherObservable** is created, which reads the file as UTF-8 and starts at the position 1024 bytes from the end.\u003cbr\u003e\n    The **watcherWorker** manages the file and notify the changes to the observable\n* (2) Start watching and split the output into line.\n* (3) Close observer and stop watching\n\n\n## License\n\n```txt\nCopyright 2017 - 2020 Blueskyfish\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of\nthis software and associated documentation files (the \"Software\"), to deal in\nthe Software without restriction, including without limitation the rights to use,\ncopy, modify, merge, publish, distribute, sublicense, and/or sell copies of the\nSoftware, and to permit persons to whom the Software is furnished to do so,\nsubject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,\nINCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A\nPARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT\nHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION\nOF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\nSOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n```\n\n## Logo\n\nIcon Experience: \u003chttps://www.iconexperience.com/\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblueskyfish%2Fendless-core","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fblueskyfish%2Fendless-core","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblueskyfish%2Fendless-core/lists"}