{"id":28028499,"url":"https://github.com/themactep/jct","last_synced_at":"2025-09-01T18:41:13.188Z","repository":{"id":291473827,"uuid":"977736109","full_name":"themactep/jct","owner":"themactep","description":"JSON configuration CLI tool","archived":false,"fork":false,"pushed_at":"2025-05-05T01:29:32.000Z","size":20,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-30T00:39:09.365Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","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/themactep.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,"zenodo":null}},"created_at":"2025-05-04T21:21:04.000Z","updated_at":"2025-05-05T01:29:35.000Z","dependencies_parsed_at":"2025-05-11T07:16:04.563Z","dependency_job_id":null,"html_url":"https://github.com/themactep/jct","commit_stats":null,"previous_names":["themactep/jct"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/themactep/jct","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/themactep%2Fjct","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/themactep%2Fjct/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/themactep%2Fjct/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/themactep%2Fjct/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/themactep","download_url":"https://codeload.github.com/themactep/jct/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/themactep%2Fjct/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273174522,"owners_count":25058469,"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","status":"online","status_checked_at":"2025-09-01T02:00:09.058Z","response_time":120,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":"2025-05-11T07:16:03.145Z","updated_at":"2025-09-01T18:41:13.156Z","avatar_url":"https://github.com/themactep.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# JSON Configuration CLI Tool\n\nA command-line tool for reading and writing JSON configuration files.\nThis tool is written in pure C with no external dependencies, making\nit suitable for cross-compilation and embedded systems.\n\n## Features\n\n- Read values from JSON configuration files using dot notation\n- Write values to JSON configuration files using dot notation\n- Create new JSON configuration files\n- Print entire JSON configuration files\n- Support for nested objects and arrays\n- Support for various data types (strings, numbers, booleans, null)\n- Pretty-printing of JSON output\n\n## Building\n\n### Native Compilation\n\nTo build the project for your local machine, run:\n\n```bash\nmake\n```\n\nThis will compile the source files and create the `jct` executable.\n\n### Cross-Compilation\n\n#### Toolchain Selection\n\nThe Makefile supports multiple toolchains using the standard `CROSS_COMPILE` prefix:\n\n```bash\n# Use prefix for a toolchain found in PATH\nmake CROSS_COMPILE=mipsel-linux-gnu-\n\n# Use any custom toolchain with a full path\nmake CROSS_COMPILE=/path/to/toolchain/bin/prefix-\n```\n\nYou can also use these toolchain options with the release target:\n\n```bash\nmake CROSS_COMPILE=/path/to/toolchain/bin/mipsel-linux-musl- release\nmake CROSS_COMPILE=mipsel-linux-gnu- release\n```\n\n### Optimized Builds\n\nFor optimized builds with smaller binary size:\n\n```bash\nmake release         # Optimized build (stripped of debug info)\n```\n\nThe optimized builds use the following techniques to reduce binary size:\n- `-Os` optimization flag for size\n- Removal of unused code with `-ffunction-sections` and `-fdata-sections`\n- Stripping of debug information\n\n### Cleaning\n\nTo clean up the build artifacts:\n\n```bash\nmake clean           # Remove object files and executables\nmake distclean       # Remove all generated files (complete cleanup)\n```\n\n## Usage\n\n```\nUsage: jct \u003cconfig_file\u003e \u003ccommand\u003e [options]\n\nCommands:\n  \u003cconfig_file\u003e get \u003ckey\u003e              Get a value from the config file\n  \u003cconfig_file\u003e set \u003ckey\u003e \u003cvalue\u003e      Set a value in the config file\n  \u003cconfig_file\u003e create                 Create a new empty config file\n  \u003cconfig_file\u003e print                  Print the entire config file\n\nExamples:\n  jct config.json get server.host       Get the server host from config.json\n  jct config.json set server.port 8080  Set the server port to 8080 in config.json\n  jct new_config.json create            Create a new empty config file\n  jct config.json print                 Print the entire config file\n```\n\n### Examples\n\n#### Creating a new configuration file\n\n```bash\n./jct new_config.json create\n```\n\n#### Setting values in a configuration file\n\n```bash\n./jct config.json set server.host localhost\n./jct config.json set server.port 8080\n./jct config.json set server.ssl true\n./jct config.json set app.name \"My Application\"\n./jct config.json set app.version 1.0\n```\n\n#### Getting values from a configuration file\n\n```bash\n./jct config.json get server.host\n# Output: localhost\n\n./jct config.json get server.port\n# Output: 8080\n\n./jct config.json get app.name\n# Output: My Application\n```\n\n#### Printing the entire configuration file\n\n```bash\n./jct config.json print\n```\n\n## Project Structure\n\n- `src/json_config.h` - Header file with type definitions and function declarations\n- `src/json_value.c` - Implementation of JSON value handling functions\n- `src/json_parse.c` - Implementation of JSON parsing functions\n- `src/json_serialize.c` - Implementation of JSON serialization functions\n- `src/json_config.c` - Implementation of configuration manipulation functions\n- `src/json_config_cli.c` - Main file with CLI interface\n- `Makefile` - Build configuration\n\n## License\n\nThis project is open source and available under the MIT License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthemactep%2Fjct","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthemactep%2Fjct","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthemactep%2Fjct/lists"}