{"id":13812823,"url":"https://github.com/daysai/cgr","last_synced_at":"2025-10-30T12:31:47.047Z","repository":{"id":33410751,"uuid":"157806741","full_name":"daysai/cgr","owner":"daysai","description":"cgr -- change registry","archived":false,"fork":false,"pushed_at":"2022-09-08T04:44:44.000Z","size":37,"stargazers_count":53,"open_issues_count":0,"forks_count":12,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-09-29T15:43:31.192Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/daysai.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":"2018-11-16T03:19:49.000Z","updated_at":"2024-08-26T02:47:35.000Z","dependencies_parsed_at":"2022-07-27T15:30:45.747Z","dependency_job_id":null,"html_url":"https://github.com/daysai/cgr","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daysai%2Fcgr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daysai%2Fcgr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daysai%2Fcgr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daysai%2Fcgr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/daysai","download_url":"https://codeload.github.com/daysai/cgr/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":219856290,"owners_count":16556085,"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-08-04T04:00:55.950Z","updated_at":"2025-10-30T12:31:41.752Z","avatar_url":"https://github.com/daysai.png","language":"JavaScript","readme":"# cgr -- change registry | yarn \u0026 npm registry manager\n\n[![npm](https://img.shields.io/npm/v/cgr.svg)](https://www.npmjs.com/package/cgr)\n[![NPM downloads](http://img.shields.io/npm/dm/cgr.svg?style=flat)](https://npmjs.org/package/cgr)\n[![dependency Status](https://snyk.io/test/npm/cgr/badge.svg?style=flat-square)](https://snyk.io/test/npm/cgr)\n\n`cgr` can help you easy and fast switch between different npm or yarn registries,\nnow include: `npm`, `cnpm`, `taobao`, `yarn`.\n\n## Install\n\n```\n$ npm install -g cgr\n```\n\n## Example\n\n```\n$ cgr ls  //* for both\n\n  npm ---- https://registry.npmjs.org/\n  cnpm --- http://r.cnpmjs.org/\n* taobao - https://registry.npmmirror.com/\n  yarn --- https://registry.yarnpkg.com/\n\n```\n\n```\n$ cgr ls  //N for npm, Y for yarn, P for pnpm\n\nN npm ---- https://registry.npmjs.org/\n  cnpm --- http://r.cnpmjs.org/\nY taobao - https://registry.npmmirror.com/\n  yarn --- https://registry.yarnpkg.com/\n\n```\n\n```\n$ cgr use cnpm  //both switch registry to cnpm\n\n    npm registry has been set to: http://r.cnpmjs.org/\n    yarn registry has been set to: http://r.cnpmjs.org/\n\n```\n\n```\n$ cgr use cnpm y  //yarn switch registry to cnpm\n\n    yarn registry has been set to: http://r.cnpmjs.org/\n\n```\n\n```\n$ cgr use cnpm n  //npm switch registry to cnpm\n\n    npm registry has been set to: http://r.cnpmjs.org/\n\n```\n\n```\n$ cgr on pnpm  //enable pnpm switch registry\n\n    cgr enable pnpm success\n\n```\n\n```\n$ cgr off pnpm  //disable pnpm switch registry\n\n    cgr disable pnpm success\n\n```\n\n```\n$ cgr use cnpm p  //pnpm switch registry to cnpm\n\n    pnpm registry has been set to: http://r.cnpmjs.org/\n\n```\n\n## Usage\n\n```\nUsage: cgr [options] [command]\n\n  Commands:\n\n    ls                           List all the registries\n    use \u003cregistry\u003e [type]        Change registry to registry\n    add \u003cregistry\u003e \u003curl\u003e [home]  Add one custom registry\n    del \u003cregistry\u003e               Delete one custom registry\n    test [registry]              Show the response time for one or all registries\n    on [type]                    Enable pnpm or other type\n    off [type]                   Disable pnpm or other type\n    help                         Print this help\n\n  Options:\n\n    -h, --help     output usage information\n    -V, --version  output the version number\n```\n\n## Registries\n\n- [npm](https://www.npmjs.org)\n- [cnpm](http://cnpmjs.org)\n- [taobao](https://npmmirror.com)\n- [yarn](https://yarnpkg.com)\n\n## Notice\n\nWhen you use an other registry, you can not use the `publish` command.\n\n## LICENSE\n\nMIT\n","funding_links":[],"categories":["工具类库"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdaysai%2Fcgr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdaysai%2Fcgr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdaysai%2Fcgr/lists"}