@@ -87,7 +87,7 @@ |
||
| 87 | 87 | $this->dockerConfig->getDockerCommand() . ' ' . $this->binaryPath . ' ' . $hook . ' "$@"' |
| 88 | 88 | ]; |
| 89 | 89 | |
| 90 | - return implode(PHP_EOL, $lines); |
|
| 90 | + return implode(PHP_EOL, $lines); |
|
| 91 | 91 | } |
| 92 | 92 | |
| 93 | 93 | /** |
@@ -60,43 +60,43 @@ discard block |
||
| 60 | 60 | { |
| 61 | 61 | parent::configure(); |
| 62 | 62 | $this->setName('install') |
| 63 | - ->setDescription('Install git hooks') |
|
| 64 | - ->setHelp('This command will install the git hooks to your .git directory') |
|
| 65 | - ->addArgument( |
|
| 66 | - 'hook', |
|
| 67 | - InputArgument::OPTIONAL, |
|
| 68 | - 'Limit the hook you want to install. By default all hooks get installed.' |
|
| 69 | - ) |
|
| 70 | - ->addOption( |
|
| 71 | - 'force', |
|
| 72 | - 'f', |
|
| 73 | - InputOption::VALUE_NONE, |
|
| 74 | - 'Force to overwrite existing hooks' |
|
| 75 | - ) |
|
| 76 | - ->addOption( |
|
| 77 | - 'bootstrap', |
|
| 78 | - null, |
|
| 79 | - InputOption::VALUE_OPTIONAL, |
|
| 80 | - 'Path to composers vendor/autoload.php' |
|
| 81 | - ) |
|
| 82 | - ->addOption( |
|
| 83 | - 'run-mode', |
|
| 84 | - 'm', |
|
| 85 | - InputOption::VALUE_OPTIONAL, |
|
| 86 | - 'Git hook run mode [php|shell|docker]' |
|
| 87 | - ) |
|
| 88 | - ->addOption( |
|
| 89 | - 'run-exec', |
|
| 90 | - 'e', |
|
| 91 | - InputOption::VALUE_OPTIONAL, |
|
| 92 | - 'The Docker command to start your container e.g. \'docker exec CONTAINER\'' |
|
| 93 | - ) |
|
| 94 | - ->addOption( |
|
| 95 | - 'run-path', |
|
| 96 | - 'p', |
|
| 97 | - InputOption::VALUE_OPTIONAL, |
|
| 98 | - 'The path to the CaptainHook executable \'/var/www/html\'' |
|
| 99 | - ); |
|
| 63 | + ->setDescription('Install git hooks') |
|
| 64 | + ->setHelp('This command will install the git hooks to your .git directory') |
|
| 65 | + ->addArgument( |
|
| 66 | + 'hook', |
|
| 67 | + InputArgument::OPTIONAL, |
|
| 68 | + 'Limit the hook you want to install. By default all hooks get installed.' |
|
| 69 | + ) |
|
| 70 | + ->addOption( |
|
| 71 | + 'force', |
|
| 72 | + 'f', |
|
| 73 | + InputOption::VALUE_NONE, |
|
| 74 | + 'Force to overwrite existing hooks' |
|
| 75 | + ) |
|
| 76 | + ->addOption( |
|
| 77 | + 'bootstrap', |
|
| 78 | + null, |
|
| 79 | + InputOption::VALUE_OPTIONAL, |
|
| 80 | + 'Path to composers vendor/autoload.php' |
|
| 81 | + ) |
|
| 82 | + ->addOption( |
|
| 83 | + 'run-mode', |
|
| 84 | + 'm', |
|
| 85 | + InputOption::VALUE_OPTIONAL, |
|
| 86 | + 'Git hook run mode [php|shell|docker]' |
|
| 87 | + ) |
|
| 88 | + ->addOption( |
|
| 89 | + 'run-exec', |
|
| 90 | + 'e', |
|
| 91 | + InputOption::VALUE_OPTIONAL, |
|
| 92 | + 'The Docker command to start your container e.g. \'docker exec CONTAINER\'' |
|
| 93 | + ) |
|
| 94 | + ->addOption( |
|
| 95 | + 'run-path', |
|
| 96 | + 'p', |
|
| 97 | + InputOption::VALUE_OPTIONAL, |
|
| 98 | + 'The path to the CaptainHook executable \'/var/www/html\'' |
|
| 99 | + ); |
|
| 100 | 100 | } |
| 101 | 101 | |
| 102 | 102 | /** |
@@ -122,11 +122,11 @@ discard block |
||
| 122 | 122 | |
| 123 | 123 | $installer = new Installer($io, $config, $repo); |
| 124 | 124 | $installer->setForce(IOUtil::argToBool($input->getOption('force'))) |
| 125 | - ->setHook(IOUtil::argToString($input->getArgument('hook'))) |
|
| 126 | - ->setTemplate( |
|
| 127 | - Template\Builder::build($config, $repo, $this->executable, $this->resolver->isPharRelease()) |
|
| 128 | - ) |
|
| 129 | - ->run(); |
|
| 125 | + ->setHook(IOUtil::argToString($input->getArgument('hook'))) |
|
| 126 | + ->setTemplate( |
|
| 127 | + Template\Builder::build($config, $repo, $this->executable, $this->resolver->isPharRelease()) |
|
| 128 | + ) |
|
| 129 | + ->run(); |
|
| 130 | 130 | |
| 131 | 131 | return 0; |
| 132 | 132 | } |