{"id":23946153,"url":"https://github.com/ermos/dotenv","last_synced_at":"2025-02-24T07:16:11.795Z","repository":{"id":57563102,"uuid":"316956121","full_name":"ermos/dotenv","owner":"ermos","description":"Go package for working with env file easily","archived":false,"fork":false,"pushed_at":"2024-05-02T09:56:26.000Z","size":12,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-06T08:37:47.374Z","etag":null,"topics":["dotenv","dotenv-parser","go","go-package","golang"],"latest_commit_sha":null,"homepage":"https://github.com/ermos/dotenv","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/ermos.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":"2020-11-29T13:22:34.000Z","updated_at":"2024-05-02T09:56:01.000Z","dependencies_parsed_at":"2024-05-02T11:05:02.092Z","dependency_job_id":"dd1ed3b6-f861-4ee7-a983-0bfcad4fea54","html_url":"https://github.com/ermos/dotenv","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ermos%2Fdotenv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ermos%2Fdotenv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ermos%2Fdotenv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ermos%2Fdotenv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ermos","download_url":"https://codeload.github.com/ermos/dotenv/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240434302,"owners_count":19800550,"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":["dotenv","dotenv-parser","go","go-package","golang"],"created_at":"2025-01-06T08:28:43.953Z","updated_at":"2025-02-24T07:16:11.704Z","avatar_url":"https://github.com/ermos.png","language":"Go","readme":"# DotEnv ♻️\n\u003e Loads environment variables from .env file with Go\n\n## Installation\n\n```bash\ngo get github.com/ermos/dotenv\n```\n\n## Usage\n\nThis package contains only one method : ``dotenv.Parse()``,\nIt allows to load a list of environment variable from an `.env` file.\n\n## Example\n\n#### .env\n```.env\ntoto=tata\nlib_desc=Loads environment variables from .env file with Go\n```\n\n#### main.go\n```go\nimport (\n \"fmt\"\n \"github.com/ermos/dotenv\"\n \"os\"\n)\n\nfunc main () {\n    // Load environment variables\n    if err := dotenv.Parse(\".env\"); err != nil {\n        log.Fatal(err)\n    }   \n    \n    fmt.Println(os.Getenv(\"lib_desc\"))\n    fmt.Printf(\"Toto is equal to %s\", os.Getenv(\"toto\"))\n}\n```\n\n#### Result\n```bash\n\u003e Loads environment variables from .env file with Go\n\u003e Toto is equal to tata\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fermos%2Fdotenv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fermos%2Fdotenv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fermos%2Fdotenv/lists"}