Just rename the readEnvFile function for testing

Until I find out how I can exclude folders from beeing deployed
Update composer ingore list
Add .gitattributes for ignore list
This commit is contained in:
2022-03-18 08:56:02 +09:00
parent f60aa3e1bc
commit 5b99da616b
4 changed files with 8 additions and 3 deletions

5
.gitattributes vendored Normal file
View File

@@ -0,0 +1,5 @@
test/ export-ignore
.gitattributes export-ignore
phpstan.neon export-ignore
psalm.xml export-ignore
.phan/ export-ignore

View File

@@ -22,6 +22,6 @@
"php": ">=7.4.0"
},
"archive": {
"exclude": ["/test/", "/phpstan.neon", "/psalm.xml", "/.phan/", "/.vscode/"]
"exclude": ["/test/", "/test/*", "/phpstan.neon", "/psalm.xml", "/.phan/", "/.vscode/"]
}
}

View File

@@ -63,7 +63,7 @@ require 'read_env_file.php';
use gullevek\AmazonIncentives\AmazonIncentives;
// load env data with dotenv
readEnvFile(__DIR__);
__readEnvFile(__DIR__);
print "<h1>Amazon Gift Card Incentives</h1><br>";

View File

@@ -21,7 +21,7 @@
* 2 for file not readable
* 3 for file not found
*/
function readEnvFile(string $path = __DIR__, string $env_file = '.env'): int
function __readEnvFile(string $path = __DIR__, string $env_file = '.env'): int
{
// default -1;
$status = -1;