{"id":17472701,"url":"https://github.com/shinnn/sum-up","last_synced_at":"2025-08-04T06:32:42.228Z","repository":{"id":23911670,"uuid":"27291881","full_name":"shinnn/sum-up","owner":"shinnn","description":"Summarize package information","archived":false,"fork":false,"pushed_at":"2017-12-11T05:16:55.000Z","size":71,"stargazers_count":15,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-11-21T08:25:00.539Z","etag":null,"topics":["cli-utility","information","javascript","nodejs","package-json","terminal"],"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/shinnn.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":"2014-11-29T05:01:23.000Z","updated_at":"2023-07-25T13:54:03.000Z","dependencies_parsed_at":"2022-08-22T07:31:21.325Z","dependency_job_id":null,"html_url":"https://github.com/shinnn/sum-up","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shinnn%2Fsum-up","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shinnn%2Fsum-up/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shinnn%2Fsum-up/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shinnn%2Fsum-up/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shinnn","download_url":"https://codeload.github.com/shinnn/sum-up/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228604603,"owners_count":17944281,"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":["cli-utility","information","javascript","nodejs","package-json","terminal"],"created_at":"2024-10-18T17:34:16.943Z","updated_at":"2024-12-07T13:15:42.772Z","avatar_url":"https://github.com/shinnn.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sum-up\n\n[![npm version](https://img.shields.io/npm/v/sum-up.svg)](https://www.npmjs.com/package/sum-up)\n[![Build Status](https://travis-ci.org/shinnn/sum-up.svg?branch=master)](https://travis-ci.org/shinnn/sum-up)\n[![Coverage Status](https://img.shields.io/coveralls/shinnn/sum-up.svg)](https://coveralls.io/r/shinnn/sum-up)\n\nSummarize package information\n\n```javascript\nconst sumUp = require('sum-up');\nconsole.log(sumUp(require('./package.json')));\n```\n\n![Screenshot](./screenshot.png \"Screenshot\")\n\nIt helps your CLI tool to display information with `--help` flag.\n\n## Installation\n\n[Use npm.](https://docs.npmjs.com/cli/install)\n\n```\nnpm install sum-up\n```\n\n## API\n\n```javascript\nconst sumUp = require('sum-up');\n```\n\n### sumUp(*pkgData* [, *option*])\n\n*pkgData*: `Object`  \n*option*: `Object`  \nReturn: `string`\n\nIt joins the `name`, `version`, `homepage` and `description` properties (all is optional) of the first argument into a string colorized with [ANSI escape code](https://github.com/sindresorhus/ansi-styles).\n\n#### option.color\n\nType: `boolean`  \nDefault: `true` if [the environment supports colors](https://github.com/sindresorhus/supports-color), otherwise `false`\n\n`false` omits all ANSI escape code from the string.\n\n```javascript\nconst data = {\n  name: 'cli-name',\n  version: '0.6.11',\n  description: 'My CLI tool.'\n}\n\nsumUp(data); //=\u003e '\\u001b[36mcli-name\\u001b[39m \\u001b[90mv0.6.11\\u001b[39m\\nMy CLI tool.'\nsumUp(data, {color: false}); //=\u003e 'cli-name v0.6.11\\nMy CLI tool.'\n```\n\n## License\n\n[ISC License](./LICENSE) © 2017 Shinnosuke Watanabe\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshinnn%2Fsum-up","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshinnn%2Fsum-up","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshinnn%2Fsum-up/lists"}