{"id":13527679,"url":"https://github.com/Kilobyte22/config-parser","last_synced_at":"2025-04-01T09:31:52.273Z","repository":{"id":57610301,"uuid":"60270143","full_name":"Kilobyte22/config-parser","owner":"Kilobyte22","description":"A simple config parser in rust","archived":false,"fork":false,"pushed_at":"2016-09-15T21:11:18.000Z","size":10,"stargazers_count":9,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-26T05:03:24.958Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Kilobyte22.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-06-02T14:18:57.000Z","updated_at":"2024-03-05T19:15:13.000Z","dependencies_parsed_at":"2022-09-26T20:02:10.605Z","dependency_job_id":null,"html_url":"https://github.com/Kilobyte22/config-parser","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kilobyte22%2Fconfig-parser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kilobyte22%2Fconfig-parser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kilobyte22%2Fconfig-parser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kilobyte22%2Fconfig-parser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Kilobyte22","download_url":"https://codeload.github.com/Kilobyte22/config-parser/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246616252,"owners_count":20806093,"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-08-01T06:01:56.768Z","updated_at":"2025-04-01T09:31:51.944Z","avatar_url":"https://github.com/Kilobyte22.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":[],"readme":"# A parser for configuration files.\n\n## Syntax\n\nThe syntax is similar to the config of nginx and pulseaudio.\n\nHere an example how an irc bot might be configured\n\n```\n# Connect to freenode\nserver freenode {\n    connect irc.freenode.net 6697 tls;\n    nick BleghBot blegh \"I am BleghBot owned by MyAdmin\";\n\n    channel \"#freenode\";\n    channel \"#secret\" mypassword;\n    \n    user MyAdmin {\n        allow all;\n    }\n\n    user ShittySpammer {\n        deny all;\n    }\n}\n```\n\n## API\nThe API is pretty simple:\n\n```rust\nextern crate config_parser;\n\nlet mut file = File::open(\"config.cfg\").unwrap();\n\nlet cfg = config_parser::parse_file(file).unwrap();\n\nfor server in cfg.matches(\"server\") {\n    let s = Server::new(server.get(0));\n\n    for channel in server.matches(\"channel\") {\n        s.add_channel(channel.get(0), channel.get_opt(1));\n    }\n}\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FKilobyte22%2Fconfig-parser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FKilobyte22%2Fconfig-parser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FKilobyte22%2Fconfig-parser/lists"}