{"id":22328765,"url":"https://github.com/seangenabe/command-join","last_synced_at":"2025-07-29T18:31:33.386Z","repository":{"id":57204018,"uuid":"47469203","full_name":"seangenabe/command-join","owner":"seangenabe","description":"Escape and join command-line arguments. Cross-platform.","archived":false,"fork":false,"pushed_at":"2019-05-23T08:15:12.000Z","size":33,"stargazers_count":7,"open_issues_count":3,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-04-25T00:34:07.524Z","etag":null,"topics":["argv","cli","command","command-line","cross-platform","escape","join","shell"],"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/seangenabe.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"license.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-12-05T19:19:18.000Z","updated_at":"2020-02-22T14:17:04.000Z","dependencies_parsed_at":"2022-09-17T18:53:43.643Z","dependency_job_id":null,"html_url":"https://github.com/seangenabe/command-join","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seangenabe%2Fcommand-join","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seangenabe%2Fcommand-join/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seangenabe%2Fcommand-join/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seangenabe%2Fcommand-join/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/seangenabe","download_url":"https://codeload.github.com/seangenabe/command-join/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228034816,"owners_count":17859246,"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":["argv","cli","command","command-line","cross-platform","escape","join","shell"],"created_at":"2024-12-04T03:13:27.241Z","updated_at":"2024-12-04T03:13:27.901Z","avatar_url":"https://github.com/seangenabe.png","language":"TypeScript","readme":"# command-join\n\nEscape command-line arguments, cross-platform.\n\n[![npm](https://img.shields.io/npm/v/command-join.svg?style=flat-square)](https://www.npmjs.com/package/command-join)\n[![Build Status](https://img.shields.io/travis/seangenabe/command-join/master.svg?style=flat-square)](https://travis-ci.org/seangenabe/command-join)\n[![devDependency Status](https://img.shields.io/david/dev/seangenabe/command-join.svg?style=flat-square)](https://david-dm.org/seangenabe/command-join#info=devDependencies)\n[![node](https://img.shields.io/node/v/command-join.svg?style=flat-square)](https://nodejs.org/en/download/)\n\nIf you like this package, be sure to star its repo, and please consider [donating](https://seangenabe.netlify.com/donate).\n\n## Usage\n\n```typescript\nimport { commandJoin } from \"command-join\"\n```\n\n### `commandJoin(arg: string | string[]): string`\n\nEscapes each command-line argument and joins them into a string that can then be executed, e.g. via `child_process.exec`.\n\nIf a string is passed, an array containing the string will instead be processed.\n\n**Example**\n\n```javascript\nconst command = commandJoin(['a', \"b\\\\\", \"'c\"])\ncommand\n// output on Windows: a \"b\\\\\" 'c\n// output on Linux: a 'b\\' \\'c\n```\n\nSee the tests for more convoluted examples.\n\n## Migrating\n\n**Migrating to v3**:\n```diff\n- const commandJoin = require(\"command-join\")\n+ const { commandJoin } = require(\"command-join\")\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseangenabe%2Fcommand-join","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fseangenabe%2Fcommand-join","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseangenabe%2Fcommand-join/lists"}