{"id":22695634,"url":"https://github.com/tina4stack/tina4php-env","last_synced_at":"2026-03-14T22:19:32.983Z","repository":{"id":57070104,"uuid":"379742419","full_name":"tina4stack/tina4php-env","owner":"tina4stack","description":"Environment support for your PHP project","archived":false,"fork":false,"pushed_at":"2025-08-19T13:29:14.000Z","size":63,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-09-16T08:35:28.507Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","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/tina4stack.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2021-06-23T22:21:08.000Z","updated_at":"2025-08-19T13:29:18.000Z","dependencies_parsed_at":"2026-03-14T21:04:13.047Z","dependency_job_id":null,"html_url":"https://github.com/tina4stack/tina4php-env","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/tina4stack/tina4php-env","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tina4stack%2Ftina4php-env","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tina4stack%2Ftina4php-env/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tina4stack%2Ftina4php-env/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tina4stack%2Ftina4php-env/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tina4stack","download_url":"https://codeload.github.com/tina4stack/tina4php-env/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tina4stack%2Ftina4php-env/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30519659,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-14T19:51:21.629Z","status":"ssl_error","status_checked_at":"2026-03-14T19:51:12.959Z","response_time":57,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":"2024-12-10T04:11:21.937Z","updated_at":"2026-03-14T22:19:32.978Z","avatar_url":"https://github.com/tina4stack.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tina4php-env\n\nEnvironment variable loader for the Tina4 PHP framework, reading `.env` files and exposing values as PHP constants and `$_ENV` entries.\n\n## Installation\n\n```bash\ncomposer require tina4stack/tina4php-env\n```\n\n## Requirements\n\n- PHP \u003e= 8.1\n\n## Usage\n\n### Basic .env File\n\nCreate a `.env` file in your project root:\n\n```ini\n[Database]\nDB_HOST=localhost\nDB_PORT=3306\nDB_NAME=myapp\n\n[App]\nAPP_DEBUG=true\nVERSION=1.0.0\n```\n\n### Loading the Environment\n\n```php\nuse Tina4\\Env;\n\n// Loads .env from the project root\nnew Env();\n\n// Access variables as constants or via $_ENV\necho DB_HOST;          // \"localhost\"\necho $_ENV[\"DB_NAME\"]; // \"myapp\"\n```\n\n### Environment-Specific Files\n\nSet an `ENVIRONMENT` OS variable to load `.env.{ENVIRONMENT}` instead:\n\n```php\n// If ENVIRONMENT=staging, loads .env.staging\nnew Env();\n\n// Or force a specific environment\nnew Env(\"production\"); // loads .env.production\n```\n\n## Testing\n\n```bash\ncomposer test\n```\n\n## License\n\nMIT - see [LICENSE](LICENSE)\n\n---\n\n## Our Sponsors\n\n**Sponsored with 🩵 by Code Infinity**\n\n[\u003cimg src=\"https://codeinfinity.co.za/wp-content/uploads/2025/09/c8e-logo-github.png\" alt=\"Code Infinity\" width=\"100\"\u003e](https://codeinfinity.co.za/about-open-source-policy?utm_source=github\u0026utm_medium=website\u0026utm_campaign=opensource_campaign\u0026utm_id=opensource)\n\n*Supporting open source communities \u003cspan style=\"color: #1DC7DE;\"\u003e•\u003c/span\u003e Innovate \u003cspan style=\"color: #1DC7DE;\"\u003e•\u003c/span\u003e Code \u003cspan style=\"color: #1DC7DE;\"\u003e•\u003c/span\u003e Empower*\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftina4stack%2Ftina4php-env","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftina4stack%2Ftina4php-env","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftina4stack%2Ftina4php-env/lists"}