From 2a6922713531a81e917242908c023e8e257c1bcc Mon Sep 17 00:00:00 2001 From: Nick Liu Date: Fri, 14 Feb 2020 12:45:45 +0100 Subject: [PATCH] Exclude Composer files in GitHub sync for e107 v2 --- e107_handlers/cron_class.php | 4 +++- e107_handlers/file_class.php | 2 ++ e107_tests/tests/unit/e_fileTest.php | 2 ++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/e107_handlers/cron_class.php b/e107_handlers/cron_class.php index efcd1f556..c5190f159 100644 --- a/e107_handlers/cron_class.php +++ b/e107_handlers/cron_class.php @@ -55,9 +55,11 @@ class _system_cron $mes->addDebug("Removed install.php"); } - if(!deftrue('e_DEVELOPER')) // leave tests folder intact if developer mode is active. + if(!deftrue('e_DEVELOPER')) // Leave development files intact if developer mode is active. { $fl->removeDir(e_BASE.'e107_tests'); + unlink(e_BASE."composer.json"); + unlink(e_BASE."composer.lock"); } } else diff --git a/e107_handlers/file_class.php b/e107_handlers/file_class.php index 7bc9a4465..dfaf83d21 100644 --- a/e107_handlers/file_class.php +++ b/e107_handlers/file_class.php @@ -1692,6 +1692,8 @@ class e_file 'e107-master/CONTRIBUTING.md', # moved to ./.github/CONTRIBUTING.md 'e107-master/LICENSE', 'e107-master/README.md', + 'e107-master/composer.json', + 'e107-master/composer.lock', 'e107-master/install.php', 'e107-master/favicon.ico', ); diff --git a/e107_tests/tests/unit/e_fileTest.php b/e107_tests/tests/unit/e_fileTest.php index 35e755dfa..3d55b5855 100644 --- a/e107_tests/tests/unit/e_fileTest.php +++ b/e107_tests/tests/unit/e_fileTest.php @@ -305,6 +305,8 @@ class e_fileTest extends \Codeception\Test\Unit '/CONTRIBUTING.md', '/LICENSE', '/README.md', + '/composer.json', + '/composer.lock', '/install.php', '/favicon.ico', ]