{"id":14985655,"url":"https://github.com/ddebin/yaml-sort","last_synced_at":"2025-04-09T14:06:43.508Z","repository":{"id":38263247,"uuid":"273177061","full_name":"ddebin/yaml-sort","owner":"ddebin","description":"CLI tool to sort YAML files alphabetically","archived":false,"fork":false,"pushed_at":"2024-12-09T19:50:25.000Z","size":66,"stargazers_count":25,"open_issues_count":0,"forks_count":6,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-02T08:48:56.834Z","etag":null,"topics":["cli","nodejs","sort","stream","yaml","yml"],"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/ddebin.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":"2020-06-18T07:58:36.000Z","updated_at":"2024-12-09T19:49:50.000Z","dependencies_parsed_at":"2025-01-15T18:18:47.436Z","dependency_job_id":"df7e0c8f-6959-41de-96c9-585998463126","html_url":"https://github.com/ddebin/yaml-sort","commit_stats":{"total_commits":29,"total_committers":3,"mean_commits":9.666666666666666,"dds":"0.24137931034482762","last_synced_commit":"cc8b2756050dcfc55e8f7a104b93912c37692de8"},"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ddebin%2Fyaml-sort","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ddebin%2Fyaml-sort/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ddebin%2Fyaml-sort/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ddebin%2Fyaml-sort/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ddebin","download_url":"https://codeload.github.com/ddebin/yaml-sort/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248054227,"owners_count":21039952,"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","nodejs","sort","stream","yaml","yml"],"created_at":"2024-09-24T14:11:26.222Z","updated_at":"2025-04-09T14:06:43.475Z","avatar_url":"https://github.com/ddebin.png","language":"JavaScript","readme":"![Node.js CI](https://github.com/ddebin/yaml-sort/workflows/Node.js%20CI/badge.svg)\n[![npm version](https://badge.fury.io/js/yaml-sort.svg)](https://www.npmjs.com/package/yaml-sort)\n\n# About\n\n`yaml-sort` sorts [YAML](https://yaml.org/) files alphabetically.\n\nThis tool is basically a tiny wrapper around [js-yaml](https://github.com/nodeca/js-yaml).\n\n(Inspired by [yml-sorter](https://github.com/42BV/yml-sorter))\n\n# Installation\n\n`npm install -g yaml-sort`\n\n# Usage\n\n```\nUsage: yaml-sort [options]\n\nOptions:\n  -i, --input         The YAML file(s) which needs to be sorted  [array] [default: STDIN]\n  -o, --output        The YAML file to output sorted content to  [string] [default: overwrite input file if specified or STDOUT]\n  -s, --stdout        Output the proposed sort to STDOUT only  [boolean]\n  -k, --check         Check if the given file(s) is already sorted  [boolean]\n      --indent, --id  Indentation width (in spaces)  [number] [default: 2]\n  -e, --encoding      Input encoding  [choices: \"ascii\", \"utf8\", \"utf16le\"] [default: \"utf8\"]\n  -q, --quotingStyle  Strings will be quoted using this quoting style  [choices: \"single\", \"double\"] [default: \"single\"]\n  -f, --forceQuotes   Force quotes for all scalar values  [boolean] [default: false]\n  -w, --lineWidth     Wrap line width (-1 for unlimited width)  [number] [default: 80]\n  -h, --help          Show help  [boolean]\n      --version       Show version number  [boolean]\n\nExamples:\n  yaml-sort --input config.yml                                 Sorts alphabetically and overwrites the file config.yml\n  yaml-sort --input config.yml --lineWidth 100 --stdout        Sorts the file config.yml and output result to STDOUT wrapped to 100 columns\n  yaml-sort --input config.yml --indent 4 --output sorted.yml  Indents with 4 spaces and outputs result to file sorted.yml\n  yaml-sort --input config.yml --forceQuotes --quotingStyle double  Forces double quotes for all scalar values\n  cat config.yml | yaml-sort                                   Sorts alphabetically from STDIN\n```","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fddebin%2Fyaml-sort","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fddebin%2Fyaml-sort","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fddebin%2Fyaml-sort/lists"}