{"id":17766625,"url":"https://github.com/floatdrop/cacha","last_synced_at":"2025-08-10T14:12:37.430Z","repository":{"id":57192392,"uuid":"45969101","full_name":"floatdrop/cacha","owner":"floatdrop","description":"Cache on file-system","archived":false,"fork":false,"pushed_at":"2015-11-15T07:53:33.000Z","size":0,"stargazers_count":21,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-30T14:45:19.105Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/floatdrop.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-11-11T08:27:12.000Z","updated_at":"2022-12-30T22:37:16.000Z","dependencies_parsed_at":"2022-09-01T06:00:44.918Z","dependency_job_id":null,"html_url":"https://github.com/floatdrop/cacha","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/floatdrop/cacha","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/floatdrop%2Fcacha","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/floatdrop%2Fcacha/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/floatdrop%2Fcacha/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/floatdrop%2Fcacha/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/floatdrop","download_url":"https://codeload.github.com/floatdrop/cacha/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/floatdrop%2Fcacha/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269734149,"owners_count":24466554,"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","status":"online","status_checked_at":"2025-08-10T02:00:08.965Z","response_time":71,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2024-10-26T20:33:31.257Z","updated_at":"2025-08-10T14:12:37.407Z","avatar_url":"https://github.com/floatdrop.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cacha [![Build Status](https://travis-ci.org/floatdrop/cacha.svg?branch=master)](https://travis-ci.org/floatdrop/cacha)\n\n\u003e Cache on file-system\n\n\n## Install\n\n```\n$ npm install --save cacha\n```\n\n\n## Usage\n\n```js\nconst Cache = require('cacha');\nconst cache = new Cacha('.my/cache');\n\ncache.set('id', 'content');\n//=\u003e Promise\n\ncache.get('id');\n//=\u003e Promise with 'content'\n```\n\n\n## API\n\n### cacha(namespace, [options])\n\n#### namespace\n\nType: `string`\n\nDirectory in HOME or TMP directory of current user.\n\nIf namespace begins with `/` it will be interpreted as absolute path.\n\n#### options\n\n##### ttl\n\nType: `Number`  \nDefault: `86400000`\n\nHow long (in milliseconds) keep entries in cache.\n\n\n### cache.get(id, [options])\n\n### cache.getSync(id, [options])\n\n### cache.set(id, content, [options])\n\n### cache.setSync(id, content, [options])\n\nGet and set methods for cache entries. `options` are passed to `fs` write and read methods (for example to specify encoding).\n\n### cache.clean()\n\nRemoves outdated entries in cache.\n\n## License\n\nMIT © [Vsevolod Strukchinsky](http://github.com/floatdrop)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffloatdrop%2Fcacha","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffloatdrop%2Fcacha","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffloatdrop%2Fcacha/lists"}