{"id":36122861,"url":"https://github.com/brianm/config-magic","last_synced_at":"2026-01-10T22:00:07.991Z","repository":{"id":685917,"uuid":"329882","full_name":"brianm/config-magic","owner":"brianm","description":"Convenience Configuration Library for Java","archived":false,"fork":false,"pushed_at":"2024-03-23T18:28:55.000Z","size":183,"stargazers_count":81,"open_issues_count":7,"forks_count":28,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-07-20T05:47:26.455Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","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/brianm.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":"2009-10-07T16:23:05.000Z","updated_at":"2024-08-18T10:18:31.000Z","dependencies_parsed_at":"2022-07-05T09:33:41.221Z","dependency_job_id":null,"html_url":"https://github.com/brianm/config-magic","commit_stats":null,"previous_names":[],"tags_count":22,"template":false,"template_full_name":null,"purl":"pkg:github/brianm/config-magic","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianm%2Fconfig-magic","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianm%2Fconfig-magic/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianm%2Fconfig-magic/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianm%2Fconfig-magic/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/brianm","download_url":"https://codeload.github.com/brianm/config-magic/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianm%2Fconfig-magic/sbom","scorecard":{"id":253279,"data":{"date":"2025-08-11","repo":{"name":"github.com/brianm/config-magic","commit":"3c5983d6ae80c5c3e44fd457e02330184a10ccc2"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.7,"checks":[{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":1,"reason":"Found 2/20 approved changesets -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 12 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-17T08:59:26.551Z","repository_id":685917,"created_at":"2025-08-17T08:59:26.551Z","updated_at":"2025-08-17T08:59:26.551Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28259557,"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":"2026-01-10T02:00:06.867Z","response_time":57,"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":"2026-01-10T22:00:07.187Z","updated_at":"2026-01-10T22:00:07.943Z","avatar_url":"https://github.com/brianm.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Example\n\nCreate an interface for your config object:\n\n    public interface MyConfig\n    {\n        @Config(\"foo\")\n        String getFoo();\n\n        @Config(\"blah\")\n        int getBlah();\n\n        @Config(\"what\")\n        @Default(\"none\")\n        String getWhat();\n    }\n\nSet the properties that we mapped with `@Config` above (or simply call `System.getProperties()`):\n\n    Properties props = new Properties();\n    props.setProperty(\"foo\", \"hello\");\n    props.setProperty(\"blah\", \"123\");\n\nThen create the config object from the properties:\n\n    ConfigurationObjectFactory factory = new ConfigurationObjectFactory(props);\n    MyConfig conf = factory.build(MyConfig.class);\n\n# Default values\n\nUsing `@Default()` can set arbitrary default values. To set `null` as the default value, use the `@DefaultNull`annotation.\n\n# Advanced usage\n\n        @Config({\"what1\", \"what2\"})\n        @Default(\"none\")\n        String getWhat();\n\nwill look at `what1` first, then at `what2` and finally fall back to the default.\n\n# Parameterized configs\n\n        enum StateType {\n           FILESYSTEM,\n           MEMORY\n        }\n        \n        @Config(\"${state_type}.size\")\n        @DefaultNull\n        String getParameterizedConfig(@Param(\"state_type\") StateType e);\n        \n        @Config(\"${state_type}.${source}.path\")\n        @DefaultNull\n        String getDoubleParameterizedConfig(@Param(\"state_type\") StateType e, @Param(\"source\") String source);\n        \n\nUse it like the following:\n        \n        myConfig.getParameterizedConfig(StateType.MEMORY);   // reads from MEMORY.size\n        myConfig.getDoubleParameterizedConfig(StateType.FILESYSTEM, \"backend\");  // reads from FILESYSTEM.backend.path\n        \n\n# Type support\n\nConfig-magic supports these types:\n\n* Primitive types: `boolean`, `byte`, `short`, `integer`, `long`, `float`, `double`.\n* Enums. Note that config-magic by default ignores the case for enum values.\n* `java.lang.String`.\n* `java.net.URI`.\n* `java.lang.Class` and simple wildcard extensions (`java.lang.Class\u003c?\u003e`, `java.lang.Class\u003c? extends Foo\u003e` - config-magic will type check that the type passed as a property conforms to the wildcard type), but not more complex wildcard or parameterized types (e.g. `java.lang.Class\u003c? super Bar\u003e` or `java.lang.Class\u003c? extends List\u003c? super Bar\u003e\u003e`).\n* `org.skipe.config.TimeSpan`: constructed from short textual representation like \"5d\" (or alias \"5 days\"); units supported are:\n * ms (alias 'milliseconds')\n * s ('seconds')\n * m ('minutes')\n * h ('hours')\n * d ('days')\n* Any instantiable class that has a public constructor with a single `Object` parameter. This is useful for instance for [joda-time](http://joda-time.sourceforge.net/)'s `DateTime` objects.\n* Any instantiable class that has a public constructor with a single `String` parameter. This is useful for instance for `java.lang.File`.\n* Any class that has a static `valueOf` method with a single `String` parameter and the class as its return type.\n\n# Maven dependency\n\nTo use config-magic in Maven projects:\n\n    \u003cdependency\u003e\n        \u003cgroupId\u003eorg.skife.config\u003c/groupId\u003e\n        \u003cartifactId\u003econfig-magic\u003c/artifactId\u003e\n        \u003cversion\u003e0.11\u003c/version\u003e\n    \u003c/dependency\u003e\n\n# Mailing List\n\nWe have a [mailing list](http://groups.google.com/group/config-magic) for development and users.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrianm%2Fconfig-magic","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbrianm%2Fconfig-magic","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrianm%2Fconfig-magic/lists"}