mirror of
https://github.com/andres-montanez/Magallanes
synced 2024-06-16 12:35:04 +02:00
Revert "[FEATURE] allow exclude definition global"
This commit is contained in:
parent
c649814158
commit
591ac04229
|
@ -54,7 +54,7 @@ class RsyncTask extends AbstractTask
|
||||||
|
|
||||||
protected function getExcludes()
|
protected function getExcludes()
|
||||||
{
|
{
|
||||||
$excludes = $this->runtime->getMergedOption('exclude', []);
|
$excludes = $this->runtime->getEnvOption('exclude', []);
|
||||||
$excludes = array_merge(['.git'], array_filter($excludes));
|
$excludes = array_merge(['.git'], array_filter($excludes));
|
||||||
|
|
||||||
foreach ($excludes as &$exclude) {
|
foreach ($excludes as &$exclude) {
|
||||||
|
|
|
@ -51,7 +51,7 @@ class PrepareTask extends AbstractTask
|
||||||
|
|
||||||
protected function getExcludes()
|
protected function getExcludes()
|
||||||
{
|
{
|
||||||
$excludes = $this->runtime->getMergedOption('exclude', []);
|
$excludes = $this->runtime->getEnvOption('exclude', []);
|
||||||
$excludes = array_merge(['.git'], array_filter($excludes));
|
$excludes = array_merge(['.git'], array_filter($excludes));
|
||||||
|
|
||||||
foreach ($excludes as &$exclude) {
|
foreach ($excludes as &$exclude) {
|
||||||
|
|
|
@ -50,27 +50,9 @@ class DeployCommandMiscTasksTest extends TestCase
|
||||||
$this->assertEquals(0, $tester->getStatusCode());
|
$this->assertEquals(0, $tester->getStatusCode());
|
||||||
}
|
}
|
||||||
|
|
||||||
public function composerFlagsDataProvider() {
|
public function testComposerFlags()
|
||||||
return [
|
|
||||||
'default' => [
|
|
||||||
'yml' => __DIR__ . '/../../Resources/composer.yml'
|
|
||||||
],
|
|
||||||
'global exclude' => [
|
|
||||||
'yml' => __DIR__ . '/../../Resources/global-exclude.yml'
|
|
||||||
],
|
|
||||||
];
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* testComposerFlags
|
|
||||||
*
|
|
||||||
* @dataProvider composerFlagsDataProvider
|
|
||||||
* @param string $yml
|
|
||||||
* @return void
|
|
||||||
*/
|
|
||||||
public function testComposerFlags($yml)
|
|
||||||
{
|
{
|
||||||
$application = new MageApplicationMockup($yml);
|
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/composer.yml');
|
||||||
|
|
||||||
/** @var AbstractCommand $command */
|
/** @var AbstractCommand $command */
|
||||||
$command = $application->find('deploy');
|
$command = $application->find('deploy');
|
||||||
|
|
|
@ -1,17 +0,0 @@
|
||||||
magephp:
|
|
||||||
log_dir: /tmp
|
|
||||||
composer:
|
|
||||||
path: /usr/bin/composer.phar
|
|
||||||
exclude:
|
|
||||||
- ./var/cache/*
|
|
||||||
- ./var/log/*
|
|
||||||
- ./web/app_dev.php
|
|
||||||
environments:
|
|
||||||
test:
|
|
||||||
user: tester
|
|
||||||
host_path: /var/www/test
|
|
||||||
hosts:
|
|
||||||
- testhost
|
|
||||||
pre-deploy:
|
|
||||||
- composer/install: { flags: '--prefer-source' }
|
|
||||||
- composer/dump-autoload: { flags: '--no-scripts' }
|
|
Loading…
Reference in a new issue