<?php
// very simple .env loader
$envFile = __DIR__ . '/../../.env';
if (is_readable($envFile)) {
  foreach (file($envFile, FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES) as $line) {
    if ($line[0]==='#') continue;
    [$k,$v] = array_map('trim', explode('=', $line, 2));
    if ($k !== '') putenv("$k=$v");
  }
}
