{"id":17422336,"url":"https://github.com/step-/json.awk","last_synced_at":"2025-04-07T05:08:40.612Z","repository":{"id":7885932,"uuid":"9262296","full_name":"step-/JSON.awk","owner":"step-","description":"Practical JSON parser written in awk","archived":false,"fork":false,"pushed_at":"2022-08-21T07:33:18.000Z","size":534,"stargazers_count":434,"open_issues_count":1,"forks_count":76,"subscribers_count":27,"default_branch":"master","last_synced_at":"2025-03-30T23:18:18.928Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Awk","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/step-.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.APACHE2","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-04-06T15:44:27.000Z","updated_at":"2025-03-17T14:30:35.000Z","dependencies_parsed_at":"2022-07-11T19:53:24.407Z","dependency_job_id":null,"html_url":"https://github.com/step-/JSON.awk","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/step-%2FJSON.awk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/step-%2FJSON.awk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/step-%2FJSON.awk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/step-%2FJSON.awk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/step-","download_url":"https://codeload.github.com/step-/JSON.awk/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247595334,"owners_count":20963943,"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-10-17T03:45:14.699Z","updated_at":"2025-04-07T05:08:40.566Z","avatar_url":"https://github.com/step-.png","language":"Awk","funding_links":[],"categories":[],"sub_categories":[],"readme":"JSON.awk\n========\n\nA practical JSON parser written in awk.\n\n[https://github.com/step-/JSON.awk](https://github.com/step-/JSON.awk)\n\nIntroduction\n------------\n\nJSON.awk is a self-contained, single-file program with no external dependencies.\nIt is similar to [JSON.sh](https://github.com/dominictarr/JSON.sh), a JSON\nparser written in Bash -- retrieved on 2013-03-13 to form the basis for\nJSON.awk. Since then the projects have separated their development paths, each\none adding new features that you will not find in the other.\n\nFeatures\n--------\n\n* Single file without external dependencies\n* Can parse multiple input files within a single invocation (one JSON text per file)\n* [Callback interface](doc/callbacks.md) (awk) to hook into parser and output events\n* [Library](doc/library.md) of practical callbacks (optional)\n* Capture invalid JSON input for further processing\n* Choice of MIT or Apache 2 license\n* JSON.sh compatible (as of 2013-03-13) default output format\n\nNon-features\n------------\n\n* Transforming input values, e.g., string/number normalization\n\nCompatibility with Awk Implementations\n--------------------------------------\n\nOf the many awk [implementations](https://en.wikipedia.org/wiki/AWK#Versions_and_implementations)\naround, JSON.awk works better with the POSIX ones and with GNU awk.\nJSON.awk is routinely tested on Linux with gawk, busybox awk and mawk in this order.\nI recommend gawk. JSON.awk does not require GNU gawk extensions, and the differences\nof running gawk with or without the `--posix` option enabled are minimal, if any.\nRunning with busybox awk requires a simple patch [FAQ](doc/FAQ.md#busybox_awk).\nRunning with mawk requires mawk version 1.3.4 20150503 or higher [FAQ](doc/FAQ.md#mawk).\n\nSupported Platforms\n-------------------\n\nAll OS platforms for which a POSIX awk implementation is available. Special cases:\n\n* macOS and FreeBSD [\u0026raquo;10](https://github.com/step-/JSON.awk/issues/10)\n* macOS [\u0026raquo;15](https://github.com/step-/JSON.awk/issues/15)\n\nConformance\n-----------\n\nThere is no official conformance test for the JSON language. Thankfully, some\nunofficial test suites exist.  JSON.awk is tested against the\n[JSONTestSuite](https://github.com/nst/JSONTestSuite.git).\n\n[Test results and comparisons](doc/JSONTestSuite/results/full_results.md)\n\nInstalling\n----------\n\nAdd files JSON.awk and optionally callbacks.awk to your project and follow the\nexamples.\n\nUsage Examples\n--------------\n\nFor full instructions please [read the docs](doc/usage.md).\nMawk users please read the [FAQ](doc/FAQ.md#mawk).\nBusybox awk users also please read the [FAQ](doc/FAQ.md#busybox_awk).\n\nPassing file names as command arguments:\n\n```sh\nawk -f JSON.awk file1.json [file2.json...]\n\nawk -f JSON.awk - \u003c file.json\n\ncat file.json | awk -f JSON.awk -\n```\n\nPassing file names on stdin:\n\n```sh\necho -e \"file1.json\\nfile2.json\" | awk -f JSON.awk\n```\n\nUsing callbacks to build a custom application ([FAQ 5](doc/FAQ.md#5)):\n\n```\nawk -f your-callbacks.awk -f JSON.awk file.json\n```\n\nApplications\n------------\n\n* [Opera-bookmarks.awk](https://github.com/step-/opera-bookmarks.awk)\n  Extract (Chromium) Opera bookmarks and QuickDial thumbnails.\n  Convert bookmark data to SQLite database and CSV file.\n\nProjects known to use JSON.awk\n------------------------------\n\n* [KindleLauncher](https://bitbucket.org/ixtab/kindlelauncher/overview)\n  a.k.a. KUAL, an application launcher for the Kindle e-ink models, uses\n  JSON.awk to parse menu descriptions.\n\nLicense\n-------\n\nThis software is available under the following licenses:\n\n* MIT\n* Apache 2\n\nCredits\n=======\n\n* [JSON.sh](https://github.com/dominictarr/JSON.sh)'s source code, retrieved on\n  2013-03-13, more than inspired version 1.0 of JSON.awk; without JSON.sh this\n  project would not exist.\n\n* [gron](https://github.com/tomnomnom/gron) for inspiration leading to\n  library module [js-dot-path.awk](doc/library.md#js_dot_path), and for some\n  test files.\n\n* [JSONTestSuite](https://github.com/nst/JSONTestSuite)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstep-%2Fjson.awk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstep-%2Fjson.awk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstep-%2Fjson.awk/lists"}