{"id":16683070,"url":"https://github.com/hlts2/appenv","last_synced_at":"2025-07-23T12:32:25.088Z","repository":{"id":144255485,"uuid":"327671355","full_name":"hlts2/appenv","owner":"hlts2","description":"Application runtime environment","archived":false,"fork":false,"pushed_at":"2021-01-21T14:11:37.000Z","size":9,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-13T12:14:28.564Z","etag":null,"topics":["appenv","env","environment-variables","go","golang","load-env","load-environment"],"latest_commit_sha":null,"homepage":"","language":"Go","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/hlts2.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}},"created_at":"2021-01-07T16:48:46.000Z","updated_at":"2021-01-21T14:11:40.000Z","dependencies_parsed_at":"2023-05-29T08:45:26.060Z","dependency_job_id":null,"html_url":"https://github.com/hlts2/appenv","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/hlts2/appenv","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hlts2%2Fappenv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hlts2%2Fappenv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hlts2%2Fappenv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hlts2%2Fappenv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hlts2","download_url":"https://codeload.github.com/hlts2/appenv/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hlts2%2Fappenv/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266679689,"owners_count":23967684,"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-07-23T02:00:09.312Z","response_time":66,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"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":["appenv","env","environment-variables","go","golang","load-env","load-environment"],"created_at":"2024-10-12T14:10:14.270Z","updated_at":"2025-07-23T12:32:24.787Z","avatar_url":"https://github.com/hlts2.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# appenv\n\n[![GoDoc](https://godoc.org/github.com/hlts2/appenv?status.svg)](http://godoc.org/github.com/hlts2/appenv)\n\nappenv is simple golang application runtime envrionment library.\n\n## Requirement\n\nGo 1.15\n\n## Installing\n\n```\ngo get github.com/hlts2/appenv\n```\n\n## Possible environment\n\n- test\n- development\n- staging\n- production\n- unknown\n\n\n## Example\n\n```go\n\npackage main\n\nimport (\n\t\"fmt\"\n\t\"os\"\n\n\t\"github.com/hlts2/appenv\"\n)\n\nfunc init() {\n\tos.Setenv(\"APP_ENV\", \"production\")\n}\n\nfunc main() {\n\tenv := appenv.Env(\"APP_ENV\")\n\n\tswitch env {\n\tcase appenv.Test:\n\t\tfmt.Println(env.String()) // test\n\tcase appenv.Dev:\n\t\tfmt.Println(env.String()) // development\n\tcase appenv.Stg:\n\t\tfmt.Println(env.String()) // staging\n\tcase appenv.Prod:\n\t\tfmt.Println(env.String()) // production\n\tdefault:\n\t\tfmt.Println(env.String()) // unknown\n\t}\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhlts2%2Fappenv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhlts2%2Fappenv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhlts2%2Fappenv/lists"}