{"id":17140486,"url":"https://github.com/nohus/autokonfig","last_synced_at":"2025-04-13T10:10:56.509Z","repository":{"id":41987055,"uuid":"233439281","full_name":"Nohus/AutoKonfig","owner":"Nohus","description":"Kotlin configuration library with batteries included","archived":false,"fork":false,"pushed_at":"2023-01-06T22:23:46.000Z","size":1714,"stargazers_count":19,"open_issues_count":0,"forks_count":4,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-27T01:35:34.868Z","etag":null,"topics":["configuration","hocon","json","kotlin","library"],"latest_commit_sha":null,"homepage":"https://autokonfig.nohus.dev/","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Nohus.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-01-12T18:32:51.000Z","updated_at":"2024-08-09T07:46:21.000Z","dependencies_parsed_at":"2023-02-06T09:47:22.746Z","dependency_job_id":null,"html_url":"https://github.com/Nohus/AutoKonfig","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Nohus%2FAutoKonfig","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Nohus%2FAutoKonfig/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Nohus%2FAutoKonfig/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Nohus%2FAutoKonfig/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Nohus","download_url":"https://codeload.github.com/Nohus/AutoKonfig/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248695481,"owners_count":21146956,"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":["configuration","hocon","json","kotlin","library"],"created_at":"2024-10-14T20:14:55.737Z","updated_at":"2025-04-13T10:10:56.490Z","avatar_url":"https://github.com/Nohus.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AutoKonfig\n\n[![AutoKonfig](https://autokonfig.nohus.dev/images/AutoKonfig.png)](https://autokonfig.nohus.dev/)\n\nKotlin configuration library with batteries included.\n\n[![License](https://img.shields.io/badge/license-Apache%202%20-blue.svg)](http://www.apache.org/licenses/LICENSE-2.0.txt)\n[![Coverage](https://img.shields.io/badge/coverage-100%25-brightgreen)](https://github.com/Nohus/AutoKonfig/tree/master/src/test/kotlin/dev/nohus/autokonfig)\n[![Version](https://img.shields.io/maven-metadata/v?metadataUrl=https%3A%2F%2Frepo1.maven.org%2Fmaven2%2Fdev%2Fnohus%2FAutoKonfig%2Fmaven-metadata.xml)](https://search.maven.org/artifact/dev.nohus/AutoKonfig)\n\n## Website\n[https://autokonfig.nohus.dev/](https://autokonfig.nohus.dev/)\n\n## Features overview\n- Support for JSON, [HOCON](https://autokonfig.nohus.dev/hocon) and Java properties config files\n- Loading config files from resources and remote URLs\n- Reading configuration from system properties and environment variables\n- Parsing command-line parameters\n- Merging properties loaded from multiple sources\n- Automatically finding config files\n- Type-safe properties\n- Support for default and optional values\n- Many useful [property types](https://autokonfig.nohus.dev/types), including dates (`2020-02-02`), times (`10:15:30`), durations (`20s`) and memory sizes (`256 MB`)\n- Type-specific parsing, a value of `1` can be the string `\"1\"`, the integer `1`, or the boolean `true`\ndepending on which type is asked for\n- Collection types\n- 100% unit test coverage\n\n## Quick start\n\n#### Gradle\n``` Groovy\nimplementation \"dev.nohus:AutoKonfig:1.1.0\"\n```\n\n#### Maven\n``` XML\n\u003cdependency\u003e\n    \u003cgroupId\u003edev.nohus\u003c/groupId\u003e\n    \u003cartifactId\u003eAutoKonfig\u003c/artifactId\u003e\n    \u003cversion\u003e1.1.0\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\nThe artifacts are available on Maven Central.\n\n## Simple example\n\nCreate a config file:\n\n#### app.conf\n``` Lighttpd\nhost = nohus.dev\nport = 80\n```\n\nCreate variables for your properties:\n\n#### Main.kt\n``` Kotlin\nfun main() {\n    val host by StringSetting()\n    val port by IntSetting()\n    println(\"Host: $host, port: $port\")\n}\n```\n\nThat's it! AutoKonfig automatically loaded your config file, because it had a [well-known name](https://autokonfig.nohus.dev/#supported-file-types). It knew which properties to load based on the variable names, and it mapped them to types based on the specified `StringSetting` and `IntSetting` delegates.\n\nTo see more, [continue reading on the website](https://autokonfig.nohus.dev/).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnohus%2Fautokonfig","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnohus%2Fautokonfig","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnohus%2Fautokonfig/lists"}