{"id":27120733,"url":"https://github.com/awatercolorpen/config","last_synced_at":"2025-04-07T10:07:32.039Z","repository":{"id":65771179,"uuid":"598109893","full_name":"AWaterColorPen/config","owner":"AWaterColorPen","description":"a lightweight pluggable dynamic config package without useless dependencies","archived":false,"fork":false,"pushed_at":"2023-02-07T02:58:16.000Z","size":34,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-06-20T06:27:10.850Z","etag":null,"topics":["config","dynamic-loading","golang","lightweight","pluggable"],"latest_commit_sha":null,"homepage":"","language":"Go","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/AWaterColorPen.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}},"created_at":"2023-02-06T12:24:39.000Z","updated_at":"2024-06-20T06:27:10.851Z","dependencies_parsed_at":"2023-02-19T14:45:44.842Z","dependency_job_id":null,"html_url":"https://github.com/AWaterColorPen/config","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/AWaterColorPen%2Fconfig","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AWaterColorPen%2Fconfig/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AWaterColorPen%2Fconfig/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AWaterColorPen%2Fconfig/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AWaterColorPen","download_url":"https://codeload.github.com/AWaterColorPen/config/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247631820,"owners_count":20970068,"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":["config","dynamic-loading","golang","lightweight","pluggable"],"created_at":"2025-04-07T10:07:31.584Z","updated_at":"2025-04-07T10:07:32.031Z","avatar_url":"https://github.com/AWaterColorPen.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# config\n\n[![Go](https://github.com/AWaterColorPen/config/actions/workflows/go.yml/badge.svg)](https://github.com/AWaterColorPen/config/actions/workflows/go.yml)\n\n## Introduction\n\nConfig is a lightweight pluggable dynamic config package without useless dependencies.\nBase on forked from [github.com/go-micro/go-micro/config](https://github.com/go-micro/go-micro/tree/master/config).\n\n## Features\n\n- dynamic loading\n- pluggable sources\n- mergeable config\n- observe changes\n- sane defaults\n\n## Getting Started\n\n### Load and get\n\nload config from `env`, `flag` and `file`.\n\n```golang\nif err := config.Load(env.NewSource()); err != nil {\n    return err\n}\n\nif err := config.Load(flag.NewSource(flag.IncludeUnset(true))); err != nil {\n    return err\n}\n\nconfigFile := \"config_file.json\"\nif err := config.Load(file.NewSource(file.WithPath(configFile))); err != nil {\n    return err\n}\n```\n\nget config to struct\n\n```golang\nfunc Scan(v any, path ...string) error {\n    return config.Get(path...).Scan(v)\n}\n```\n\n## License\n\nSee the [License File](./LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fawatercolorpen%2Fconfig","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fawatercolorpen%2Fconfig","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fawatercolorpen%2Fconfig/lists"}