From 06340867d3b7ffce90f5d8da2811274af49774ee Mon Sep 17 00:00:00 2001 From: StyleCI Bot Date: Mon, 2 May 2022 13:56:33 +0000 Subject: [PATCH] Apply fixes from StyleCI --- spec/PHPCR/Shell/Event/ProfileInitEventSpec.php | 4 +++- spec/PHPCR/Shell/Serializer/YamlEncoderSpec.php | 5 +++-- src/PHPCR/Shell/Config/Profile.php | 6 ++++-- src/PHPCR/Shell/Config/ProfileLoader.php | 9 ++++++--- .../Phpcr/AccessControlPrivilegeListCommand.php | 5 +++-- .../Shell/Console/Command/Phpcr/LockInfoCommand.php | 3 ++- .../Shell/Console/Command/Phpcr/LockLockCommand.php | 3 ++- .../Console/Command/Phpcr/LockRefreshCommand.php | 3 ++- .../Console/Command/Phpcr/LockTokenAddCommand.php | 3 ++- .../Console/Command/Phpcr/LockTokenListCommand.php | 3 ++- .../Console/Command/Phpcr/LockTokenRemoveCommand.php | 3 ++- .../Console/Command/Phpcr/LockUnlockCommand.php | 3 ++- .../Shell/Console/Command/Phpcr/NodeCloneCommand.php | 3 ++- .../Shell/Console/Command/Phpcr/NodeCopyCommand.php | 3 ++- .../Command/Phpcr/NodeCorrespondingCommand.php | 3 ++- .../Console/Command/Phpcr/NodeCreateCommand.php | 3 ++- .../Shell/Console/Command/Phpcr/NodeEditCommand.php | 3 ++- .../Console/Command/Phpcr/NodeFileImportCommand.php | 3 ++- .../Shell/Console/Command/Phpcr/NodeInfoCommand.php | 3 ++- .../Command/Phpcr/NodeLifecycleFollowCommand.php | 3 ++- .../Command/Phpcr/NodeLifecycleListCommand.php | 3 ++- .../Shell/Console/Command/Phpcr/NodeListCommand.php | 12 ++++++++---- .../Console/Command/Phpcr/NodeMixinAddCommand.php | 3 ++- .../Console/Command/Phpcr/NodeMixinRemoveCommand.php | 3 ++- .../Shell/Console/Command/Phpcr/NodeMoveCommand.php | 3 ++- .../Console/Command/Phpcr/NodeOrderBeforeCommand.php | 3 ++- .../Command/Phpcr/NodePropertyRemoveCommand.php | 6 ++++-- .../Console/Command/Phpcr/NodePropertySetCommand.php | 3 ++- .../Command/Phpcr/NodePropertyShowCommand.php | 3 ++- .../Console/Command/Phpcr/NodeReferencesCommand.php | 5 +++-- .../Console/Command/Phpcr/NodeRemoveCommand.php | 3 ++- .../Console/Command/Phpcr/NodeRenameCommand.php | 3 ++- .../Command/Phpcr/NodeSetPrimaryTypeCommand.php | 3 ++- .../Console/Command/Phpcr/NodeSharedShowCommand.php | 3 ++- .../Console/Command/Phpcr/NodeTypeEditCommand.php | 3 ++- .../Console/Command/Phpcr/NodeTypeListCommand.php | 3 ++- .../Console/Command/Phpcr/NodeTypeLoadCommand.php | 6 ++++-- .../Console/Command/Phpcr/NodeTypeShowCommand.php | 7 +++++-- .../Command/Phpcr/NodeTypeUnregisterCommand.php | 3 ++- .../Console/Command/Phpcr/NodeUpdateCommand.php | 3 ++- .../Shell/Console/Command/Phpcr/QueryCommand.php | 3 ++- .../Console/Command/Phpcr/QueryDeleteCommand.php | 6 ++++-- .../Console/Command/Phpcr/QuerySelectCommand.php | 3 ++- .../Console/Command/Phpcr/QueryUpdateCommand.php | 3 ++- .../Phpcr/RepositoryDescriptorListCommand.php | 3 ++- .../Command/Phpcr/RetentionHoldAddCommand.php | 3 ++- .../Command/Phpcr/RetentionHoldListCommand.php | 3 ++- .../Command/Phpcr/RetentionHoldRemoveCommand.php | 7 +++++-- .../Command/Phpcr/RetentionPolicyGetCommand.php | 3 ++- .../Command/Phpcr/RetentionPolicyRemoveCommand.php | 3 ++- .../Console/Command/Phpcr/SessionExportCommand.php | 3 ++- .../Command/Phpcr/SessionImpersonateCommand.php | 3 ++- .../Console/Command/Phpcr/SessionImportCommand.php | 6 ++++-- .../Console/Command/Phpcr/SessionInfoCommand.php | 3 ++- .../Console/Command/Phpcr/SessionLoginCommand.php | 3 ++- .../Console/Command/Phpcr/SessionLogoutCommand.php | 3 ++- .../Command/Phpcr/SessionNamespaceListCommand.php | 3 ++- .../Command/Phpcr/SessionNamespaceSetCommand.php | 3 ++- .../Console/Command/Phpcr/SessionRefreshCommand.php | 3 ++- .../Console/Command/Phpcr/SessionSaveCommand.php | 3 ++- .../Console/Command/Phpcr/VersionCheckinCommand.php | 5 +++-- .../Console/Command/Phpcr/VersionCheckoutCommand.php | 3 ++- .../Command/Phpcr/VersionCheckpointCommand.php | 3 ++- .../Console/Command/Phpcr/VersionHistoryCommand.php | 3 ++- .../Console/Command/Phpcr/VersionRemoveCommand.php | 3 ++- .../Console/Command/Phpcr/VersionRestoreCommand.php | 3 ++- .../Console/Command/Phpcr/WorkspaceCreateCommand.php | 3 ++- .../Console/Command/Phpcr/WorkspaceDeleteCommand.php | 3 ++- .../Console/Command/Phpcr/WorkspaceListCommand.php | 3 ++- .../Command/Phpcr/WorkspaceNamespaceListCommand.php | 3 ++- .../Phpcr/WorkspaceNamespaceRegisterCommand.php | 3 ++- .../Phpcr/WorkspaceNamespaceUnregisterCommand.php | 3 ++- .../Console/Command/Phpcr/WorkspaceUseCommand.php | 3 ++- .../Shell/Console/Command/Shell/AliasListCommand.php | 3 ++- .../Shell/Console/Command/Shell/ClearCommand.php | 3 ++- .../Console/Command/Shell/ConfigInitCommand.php | 3 ++- .../Console/Command/Shell/ConfigReloadCommand.php | 3 ++- .../Console/Command/Shell/ProfileShowCommand.php | 3 ++- src/PHPCR/Shell/Console/Helper/NodeHelper.php | 3 ++- .../Shell/Console/Helper/ResultFormatterHelper.php | 9 ++++++--- src/PHPCR/Shell/Console/Helper/TextHelper.php | 6 ++++-- src/PHPCR/Shell/Query/FunctionOperand.php | 3 ++- src/PHPCR/Shell/Serializer/NodeNormalizer.php | 3 ++- .../Subscriber/ProfileFromSessionInputSubscriber.php | 4 +++- .../Shell/Subscriber/ProfileLoaderSubscriber.php | 3 ++- tests/PHPCR/Shell/Helper/EditorHelperTest.php | 9 ++++++--- 86 files changed, 214 insertions(+), 107 deletions(-) diff --git a/spec/PHPCR/Shell/Event/ProfileInitEventSpec.php b/spec/PHPCR/Shell/Event/ProfileInitEventSpec.php index beba4777..3beccd14 100644 --- a/spec/PHPCR/Shell/Event/ProfileInitEventSpec.php +++ b/spec/PHPCR/Shell/Event/ProfileInitEventSpec.php @@ -30,7 +30,9 @@ public function let( OutputInterface $output ) { $this->beConstructedWith( - $profile, $input, $output + $profile, + $input, + $output ); } diff --git a/spec/PHPCR/Shell/Serializer/YamlEncoderSpec.php b/spec/PHPCR/Shell/Serializer/YamlEncoderSpec.php index 7fde3963..330f2cc5 100644 --- a/spec/PHPCR/Shell/Serializer/YamlEncoderSpec.php +++ b/spec/PHPCR/Shell/Serializer/YamlEncoderSpec.php @@ -24,12 +24,13 @@ public function it_is_initializable() public function it_should_encode_to_yaml() { $data = ['foobar' => 'barfoo', 'barfoo' => 'foobar']; - $this->encode($data, 'yaml')->shouldReturn(<<<'EOT' + $this->encode($data, 'yaml')->shouldReturn( + <<<'EOT' foobar: barfoo barfoo: foobar EOT - ); + ); } public function is_should_decode_yaml() diff --git a/src/PHPCR/Shell/Config/Profile.php b/src/PHPCR/Shell/Config/Profile.php index 67e4cd60..a95c3c15 100644 --- a/src/PHPCR/Shell/Config/Profile.php +++ b/src/PHPCR/Shell/Config/Profile.php @@ -44,7 +44,8 @@ protected function validateDomain($domain) if (!array_key_exists($domain, $this->profile)) { throw new \InvalidArgumentException(sprintf( 'Unknown profile domain "%s", can only use one of: %s', - $domain, implode(', ', array_keys($this->profile)) + $domain, + implode(', ', array_keys($this->profile)) )); } } @@ -87,7 +88,8 @@ public function get($domain, $key = null) if (!isset($this->profile[$domain][$key])) { throw new \InvalidArgumentException(sprintf( 'Unknown key "%s" for profile domain "%s"', - $key, $domain + $key, + $domain )); } diff --git a/src/PHPCR/Shell/Config/ProfileLoader.php b/src/PHPCR/Shell/Config/ProfileLoader.php index 25864162..a9802e20 100644 --- a/src/PHPCR/Shell/Config/ProfileLoader.php +++ b/src/PHPCR/Shell/Config/ProfileLoader.php @@ -69,8 +69,10 @@ public function loadProfile(Profile $profile) $path = $this->getProfilePath($profile->getName()); if (!file_exists($path)) { - throw new \InvalidArgumentException(sprintf('Profile "%s" does not exist, expected to find it in "%s"', - $profile->getName(), $path + throw new \InvalidArgumentException(sprintf( + 'Profile "%s" does not exist, expected to find it in "%s"', + $profile->getName(), + $path )); } @@ -99,7 +101,8 @@ public function saveProfile(Profile $profile, $overwrite = false) if (false === $overwrite && file_exists($path)) { throw new FileExistsException(sprintf( - 'Profile already exists at "%s"', $path + 'Profile already exists at "%s"', + $path )); } diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/AccessControlPrivilegeListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/AccessControlPrivilegeListCommand.php index 8c0189ab..87fe2fdc 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/AccessControlPrivilegeListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/AccessControlPrivilegeListCommand.php @@ -27,7 +27,8 @@ protected function configure() $this->setDescription('List the privileges of the repository or a specific node'); $this->addArgument('absPath', InputArgument::OPTIONAL, 'Absolute path for node, optional.'); $this->addOption('supported', null, InputOption::VALUE_NONE, 'List privileges supported by repository rather than current session.'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' NOTE: This command is not supported by Jackrabbit. List the privileges of the current session or the node at the given path. @@ -49,7 +50,7 @@ protected function configure() list the privileges held by the current session, but rather the privileges supported by the repository. HERE - ); + ); $this->requiresDescriptor(RepositoryInterface::OPTION_ACCESS_CONTROL_SUPPORTED, true); } diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/LockInfoCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/LockInfoCommand.php index d702686a..1d5f1a2f 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/LockInfoCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/LockInfoCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setName('lock:info'); $this->setDescription('Show details of the lock that applies to the specified node path'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of locked node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Shows the details of the lock that applies to the node at the specified path. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/LockLockCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/LockLockCommand.php index 30c17a01..83b9d5d8 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/LockLockCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/LockLockCommand.php @@ -29,7 +29,8 @@ protected function configure() $this->addOption('session-scoped', null, InputOption::VALUE_NONE, 'If given, this lock expires with the current session; if not it expires when explicitly or automatically unlocked for some other reason'); $this->addOption('timeout', null, InputOption::VALUE_REQUIRED, 'Desired lock timeout in seconds (servers are free to ignore this value). If not used lock will not timeout'); $this->addOption('owner-info', null, InputOption::VALUE_REQUIRED, ' string containing owner information supplied by the client; servers are free to ignore this value. If none is specified, the implementation chooses one (i.e. user name of current backend authentication credentials'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Places a lock on the node at path. If successful, the node is said to hold the lock. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/LockRefreshCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/LockRefreshCommand.php index b3591714..804bdd62 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/LockRefreshCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/LockRefreshCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('lock:refresh'); $this->setDescription('Refresh the TTL of the lock of the node at the given path'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node containing the lock to be refreshed'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' If this lock's time-to-live is governed by a timer, this command resets that timer so that the lock does not timeout and expire. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenAddCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenAddCommand.php index 60087e35..51307268 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenAddCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenAddCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('lock:token:add'); $this->setDescription('Add a lock token to the current session'); $this->addArgument('lockToken', InputArgument::REQUIRED, 'Lock token'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Adds the specified lock token to the current Session. Holding a lock token makes the current Session the owner of the lock diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenListCommand.php index 4546b559..4bf3171f 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenListCommand.php @@ -23,7 +23,8 @@ protected function configure() { $this->setName('lock:token:list'); $this->setDescription('List a lock token to the current session'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Show a list of previously registered tokens. Displays all lock tokens currently held by the diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenRemoveCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenRemoveCommand.php index fcb45a33..b73d3935 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenRemoveCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/LockTokenRemoveCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('lock:token:remove'); $this->setDescription('Remove a lock token to the current session'); $this->addArgument('lockToken', InputArgument::REQUIRED, 'Lock token'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Removes the specified lock token from the current Session. HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/LockUnlockCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/LockUnlockCommand.php index c4031cc0..34fd1f94 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/LockUnlockCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/LockUnlockCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('lock:unlock'); $this->setDescription('Unlock the node at the given path'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Removes the lock on the node at path. Also removes the properties jcr:lockOwner and jcr:lockIsDeep from that diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeCloneCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeCloneCommand.php index 1baf9ee3..37fcde2e 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeCloneCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeCloneCommand.php @@ -27,7 +27,8 @@ protected function configure() $this->addArgument('destPath', InputArgument::REQUIRED, 'Path to destination node'); $this->addArgument('srcWorkspace', InputArgument::OPTIONAL, 'If specified, copy from this workspace'); $this->addOption('remove-existing', null, InputOption::VALUE_NONE, 'Remove existing nodes'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Clones the subgraph at the node srcAbsPath in srcWorkspace to the new location at destAbsPath in the current workspace. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeCopyCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeCopyCommand.php index d597197c..d6b77a2a 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeCopyCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeCopyCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->addArgument('srcPath', InputArgument::REQUIRED, 'Path to source node'); $this->addArgument('destPath', InputArgument::REQUIRED, 'Path to destination node'); $this->addArgument('srcWorkspace', InputArgument::OPTIONAL, 'If specified, copy from this workspace'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Copies a Node including its children to a new location to the given workspace. This method copies the subgraph rooted at, and including, the node at diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeCorrespondingCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeCorrespondingCommand.php index 116c08f0..baa7033a 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeCorrespondingCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeCorrespondingCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Show the path for the current nodes corresponding path in named workspace'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); $this->addArgument('workspaceName', InputArgument::REQUIRED, 'The name of the workspace'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Returns the absolute path of the node in the specified workspace that corresponds to this node. HERE diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeCreateCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeCreateCommand.php index 87665ec5..686fac05 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeCreateCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeCreateCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Create a node at the current path'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node to create'); $this->addArgument('primaryNodeTypeName', InputArgument::OPTIONAL, 'Optional name of primary node type to use'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Creates a new node at the specified path This is session-write method, meaning that the addition of the new node diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeEditCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeEditCommand.php index ed5c1fc2..2492ba21 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeEditCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeEditCommand.php @@ -31,7 +31,8 @@ protected function configure() $this->setDescription('Edit the given node in the EDITOR configured by the system'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); $this->addOption('type', null, InputOption::VALUE_REQUIRED, 'Optional type to use when creating new nodes', 'nt:unstructured'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Edit or create a node at the given path using the default editor as defined by the EDITOR environment variable. When you invoke the command a temporary file in YAML format will be created on the filesystem. This file will diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeFileImportCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeFileImportCommand.php index f81f903f..39cebde5 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeFileImportCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeFileImportCommand.php @@ -35,7 +35,8 @@ protected function configure() $this->addOption('mime-type', null, InputOption::VALUE_REQUIRED, 'Mime type (optional, auto-detected)'); $this->addOption('force', null, InputOption::VALUE_NONE, 'Force overwriting any existing node'); $this->addOption('no-container', null, InputOption::VALUE_NONE, 'Do not wrap in a JCR nt:file, but write directly to the specified property'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Import an external file into the repository. The file will be imported as a node of built-in type nt:file. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeInfoCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeInfoCommand.php index 04732afe..396819d0 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeInfoCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeInfoCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('node:info'); $this->setDescription('Show information about the current node'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Show information about the node(s) at the given path: PHPCRSH> node:info path/to/node diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeLifecycleFollowCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeLifecycleFollowCommand.php index 829b8600..575197ef 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeLifecycleFollowCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeLifecycleFollowCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setDescription('Causes the lifecycle state of this node to undergo the specified transition.'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); $this->addArgument('transition', InputArgument::REQUIRED, 'A state transition'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Causes the lifecycle state of the current node to undergo the specified transition. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeLifecycleListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeLifecycleListCommand.php index 70d93e4c..749f8f91 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeLifecycleListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeLifecycleListCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('node:lifecycle:list'); $this->setDescription('Returns the list of valid state transitions for this node.'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Returns the list of valid state transitions for this node. HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeListCommand.php index e3ff7425..b06c4a8f 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeListCommand.php @@ -46,7 +46,8 @@ protected function configure() 'Sort properties, one of: %s', implode(', ', $this->sortOptions) ), 'asc'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' List both or one of the children and properties of this node. Multiple levels can be shown by using the --level option. @@ -123,7 +124,8 @@ public function execute(InputInterface $input, OutputInterface $output) $this->renderNode($node, $table, [], $filter); if ($table->getNumberOfRows() > 0) { - $output->writeln(sprintf('%s [%s] > %s', + $output->writeln(sprintf( + '%s [%s] > %s', $node->getPath(), $node->getPrimaryNodeType()->getName(), implode(', ', $node->getPrimaryNodeType()->getDeclaredSupertypeNames()) @@ -133,11 +135,13 @@ public function execute(InputInterface $input, OutputInterface $output) } if ($config['show_execution_time_list']) { - $output->writeln(sprintf( + $output->writeln( + sprintf( '%s nodes, %s properties in set (%s sec)', $this->nbNodes, $this->nbProperties, - number_format($this->time, $config['execution_time_expansion'])) + number_format($this->time, $config['execution_time_expansion']) + ) ); } diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeMixinAddCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeMixinAddCommand.php index efcb958a..d1566761 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeMixinAddCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeMixinAddCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Add the named mixin to the node (can include wildcards)'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); $this->addArgument('mixinName', InputArgument::REQUIRED, 'The name of the mixin node type to be added'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Adds the mixin node type named mixinName to the node(s) inferred by the path. If this node is already of type mixinName (either due to a previously diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeMixinRemoveCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeMixinRemoveCommand.php index c6ece3ea..41abd7c4 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeMixinRemoveCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeMixinRemoveCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Remove the named mixin to the current node'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node (can include wildcards)'); $this->addArgument('mixinName', InputArgument::REQUIRED, 'The name of the mixin node type to be removeed'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Removes the specified mixin node type from this node and removes mixinName from this node's jcr:mixinTypes property. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeMoveCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeMoveCommand.php index 73cf3b75..b2af8fd1 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeMoveCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeMoveCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Move a node in the current session'); $this->addArgument('srcPath', InputArgument::REQUIRED, 'The root of the subgraph to be moved.'); $this->addArgument('destPath', InputArgument::REQUIRED, 'The location to which the subgraph is to be moved'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Moves the node at srcPath (and its entire subgraph) to the new location at destPath. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeOrderBeforeCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeOrderBeforeCommand.php index a8121ba0..7b140c17 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeOrderBeforeCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeOrderBeforeCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); $this->addArgument('srcChildRelPath', InputArgument::REQUIRED, 'The relative path to the child node to be moved in the ordering'); $this->addArgument('destChildRelPath', InputArgument::REQUIRED, 'The relative path to the child before which the node srcChildRelPath will be placed'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' This command is used to change the order of a child node relative to the current node. For example, given that the node /foobar has the children child2 and diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertyRemoveCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertyRemoveCommand.php index d13ae934..f6824181 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertyRemoveCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertyRemoveCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('node:property:remove'); $this->setDescription('Remove the property at the given absolute path'); $this->addArgument('absPath', InputArgument::REQUIRED, 'Absolute path to property'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Remove the property from the current session at the given path HERE ); @@ -39,7 +40,8 @@ public function execute(InputInterface $input, OutputInterface $output) $property = $session->getProperty($absPath); } catch (PathNotFoundException $e) { throw new \Exception(sprintf( - 'Could not find a property at "%s"', $absPath + 'Could not find a property at "%s"', + $absPath )); } diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertySetCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertySetCommand.php index 6f118338..3b29daac 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertySetCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertySetCommand.php @@ -29,7 +29,8 @@ protected function configure() $this->addArgument('path', InputArgument::REQUIRED, 'Path of property - parent path can include wildcards'); $this->addArgument('value', InputArgument::OPTIONAL, 'Value for named property'); $this->addOption('type', null, InputOption::VALUE_REQUIRED, 'Type of named property'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Defines or set a value for a property identified by its name. PHPCRSH> node:property:set . propname "some value" --type="String" diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertyShowCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertyShowCommand.php index 53e4cd32..5e956233 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertyShowCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodePropertyShowCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('node:property:show'); $this->setDescription('Show the property at the given path'); $this->addArgument('path', InputArgument::REQUIRED, 'Path to property (can include wildcards)'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Show the full value of a property at the given path HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeReferencesCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeReferencesCommand.php index efdf142f..5231485b 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeReferencesCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeReferencesCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setDescription('Returns all REFERENCE properties that refer to this node'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node (can include wildcard)'); $this->addArgument('name', InputArgument::OPTIONAL, 'Limit references to given name'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' This command returns all REFERENCE properties that refer to this node, have the specified name and that are accessible through the current Session. @@ -33,7 +34,7 @@ protected function configure() If the name parameter is null then all referring REFERENCES are returned regardless of name. HERE - ); + ); } public function execute(InputInterface $input, OutputInterface $output) diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeRemoveCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeRemoveCommand.php index 919e0759..51bf1d1c 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeRemoveCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeRemoveCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setDescription('Remove the node at path (can include wildcards)'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); $this->addOption('shared', null, InputOption::VALUE_NONE, 'Remove nodes in shared set'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Remove the node at the given path. If the `--shared` option is specified then any nodes within this nodes diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeRenameCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeRenameCommand.php index 6fc753b6..53315549 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeRenameCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeRenameCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Rename the node at the current path'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node'); $this->addArgument('newName', InputArgument::REQUIRED, 'The name of the node to create'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Renames this node to the specified newName. The ordering (if any) of this node among it siblings remains unchanged. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeSetPrimaryTypeCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeSetPrimaryTypeCommand.php index aa825ddf..209335c9 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeSetPrimaryTypeCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeSetPrimaryTypeCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Set the primary type of the current node'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node (can include wildcard)'); $this->addArgument('nodeTypeName', InputArgument::REQUIRED, 'New primary node type name'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Changes the primary node type of this node to nodeTypeName. Also immediately changes this node's jcr:primaryType property diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeSharedShowCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeSharedShowCommand.php index e2402645..1467da19 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeSharedShowCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeSharedShowCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('node:shared:show'); $this->setDescription('Show all the nodes are in the shared set of this node'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node (can include wildcard)'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Lists all nodes that are in the shared set of this node. Shareable nodes are analagous to symbolic links in a linux filesystem and can diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeEditCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeEditCommand.php index 5452daa0..7762f88b 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeEditCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeEditCommand.php @@ -27,7 +27,8 @@ protected function configure() $this->setName('node-type:edit'); $this->setDescription('Edit or create a node type'); $this->addArgument('nodeTypeName', InputArgument::REQUIRED, 'The name of the node type to edit or create'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Edit the given node type name with the editor defined in the EDITOR environment variable. If the node type does not exist, it will be created. All node types must be prefixed with diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeListCommand.php index e0b90a5a..0300ec19 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeListCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('node-type:list'); $this->setDescription('List registered node types'); $this->addArgument('filter', InputArgument::OPTIONAL, 'Perl regexp pattern'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' List all node types (both primary and mixins) a filter can be optionally passed: PHPCRSH> node-type:list --filter mix:.* diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeLoadCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeLoadCommand.php index 608fcd18..f14d5fd6 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeLoadCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeLoadCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setDescription('Load or create a node type'); $this->addOption('update', null, InputOption::VALUE_NONE, 'Update existing node type'); $this->addArgument('cndFile', InputArgument::REQUIRED, 'The name file containing the CND data'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' This command allows to register node types in the repository that are defined in a CND (Compact Namespace and Node Type Definition) file as used by jackrabbit. @@ -50,7 +51,8 @@ public function execute(InputInterface $input, OutputInterface $output) if (!file_exists($cndFile)) { throw new \InvalidArgumentException(sprintf( - 'The CND file "%s" does not exist.', $cndFile + 'The CND file "%s" does not exist.', + $cndFile )); } diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeShowCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeShowCommand.php index 361cf498..0e60efaa 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeShowCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeShowCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setName('node-type:show'); $this->setDescription('Show the CND of a node type'); $this->addArgument('nodeTypeName', InputArgument::REQUIRED, 'The name of the node type to show'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Show the CND (Compact Node Definition) of a given node type. HERE ); @@ -43,7 +44,9 @@ public function execute(InputInterface $input, OutputInterface $output) $nodeType = $nodeTypeManager->getNodeType($nodeTypeName); } catch (NoSuchNodeTypeException $e) { throw new \Exception(sprintf( - 'The node type "%s" does not exist', $nodeTypeName)); + 'The node type "%s" does not exist', + $nodeTypeName + )); } $cndWriter = new CndWriter($namespaceRegistry); $out = $cndWriter->writeString([$nodeType]); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeUnregisterCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeUnregisterCommand.php index 9bb3a764..7e7cf649 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeUnregisterCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeTypeUnregisterCommand.php @@ -23,7 +23,8 @@ protected function configure() $this->setName('node-type:unregister'); $this->setDescription('Unregister a node type UNSUPPORTED / TODO'); $this->addArgument('nodeTypeName', InputArgument::REQUIRED, 'The name of the node type to unregister'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Unregisters the specified node type HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/NodeUpdateCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/NodeUpdateCommand.php index 9783b313..dc44a32f 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/NodeUpdateCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/NodeUpdateCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Updates a node corresponding to the given path in the given workspace'); $this->addArgument('path', InputArgument::REQUIRED, 'Path of node (can include wildcards)'); $this->addArgument('srcWorkspace', InputArgument::REQUIRED, 'The name of the source workspace'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Updates a node corresponding to the current one in the given workspace. If this node does have a corresponding node in the workspace diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/QueryCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/QueryCommand.php index 3c209aea..f7cdce19 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/QueryCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/QueryCommand.php @@ -27,7 +27,8 @@ protected function configure() $this->addOption('language', 'l', InputOption::VALUE_OPTIONAL, 'The query language (e.g. jcr-sql2', 'JCR-SQL2'); $this->addOption('limit', null, InputOption::VALUE_OPTIONAL, 'The query limit', 0); $this->addOption('offset', null, InputOption::VALUE_OPTIONAL, 'The query offset', 0); - $this->setHelp(<<<'EOT' + $this->setHelp( + <<<'EOT' Execute an SQL query. This command differs from select in that it is executed conventionally and not literally. The advantage is that you can specify a specific query language and additional options: diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/QueryDeleteCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/QueryDeleteCommand.php index 88695a2b..8ad7be4a 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/QueryDeleteCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/QueryDeleteCommand.php @@ -23,7 +23,8 @@ protected function configure() $this->setName('delete'); $this->setDescription('Execute a DELETE query (non standard)'); $this->addArgument('query'); - $this->setHelp(<<<'EOT' + $this->setHelp( + <<<'EOT' Execute a DELETE query. Unlike other commands you can enter a query literally: DELETE FROM [nt:unstructured] WHERE title = 'foo'; @@ -42,7 +43,8 @@ public function execute(InputInterface $input, OutputInterface $output) if (!preg_match('{^delete from}', strtolower($sql))) { throw new \PHPCR\Query\InvalidQueryException(sprintf( - '"FROM" not specified in DELETE query: "%s"', $sql + '"FROM" not specified in DELETE query: "%s"', + $sql )); } diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/QuerySelectCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/QuerySelectCommand.php index ac338442..1645ab82 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/QuerySelectCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/QuerySelectCommand.php @@ -22,7 +22,8 @@ protected function configure() $this->setName('select'); $this->setDescription('Execute a SELECT query (JCR-SQL2)'); $this->addArgument('query'); - $this->setHelp(<<<'EOT' + $this->setHelp( + <<<'EOT' Execute a JCR-SQL2 query. Unlike other commands you can enter a query literally: SELECT * FROM [nt:unstructured]; diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/QueryUpdateCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/QueryUpdateCommand.php index 408aee6c..206bc7d9 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/QueryUpdateCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/QueryUpdateCommand.php @@ -28,7 +28,8 @@ protected function configure() $this->setName('update'); $this->setDescription('Execute an UPDATE query (non-standard)'); $this->addArgument('query'); - $this->setHelp(<<<'EOT' + $this->setHelp( + <<<'EOT' Execute a PHPCR-Shell JCR-SQL2 update query. You can enter a query literally: UPDATE [nt:unstructured] AS a SET title = 'foobar' WHERE a.title = 'barfoo'; diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/RepositoryDescriptorListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/RepositoryDescriptorListCommand.php index 9262d32f..13cfe16e 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/RepositoryDescriptorListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/RepositoryDescriptorListCommand.php @@ -22,7 +22,8 @@ protected function configure() { $this->setName('repository:descriptor:list'); $this->setDescription('List the descriptors for the current repository'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Repositories indicate support for the JCR specification via. descriptors. This command lists all of the descriptor keys and values for the current repository. HERE diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldAddCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldAddCommand.php index 71be906d..c8ba74ff 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldAddCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldAddCommand.php @@ -27,7 +27,8 @@ protected function configure() $this->addArgument('absPath', InputArgument::REQUIRED, 'Absolute path to node to which we want to add a hold'); $this->addArgument('name', InputArgument::REQUIRED, 'Name of hold to add'); $this->addOption('deep', null, InputOption::VALUE_NONE, 'Apply hold also to the children of specified node.'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Places a hold on the existing node at absPath. If the is-deep is true the hold applies to this node and its diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldListCommand.php index f7a3b7db..4b221c05 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldListCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setName('retention:hold:list'); $this->setDescription('List retention holds at given absolute path UNSUPPORTED'); $this->addArgument('absPath', InputArgument::REQUIRED, 'Absolute path to node to which we want to add a hold'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Lists all hold object names that have been added to the existing node at absPath. HERE diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldRemoveCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldRemoveCommand.php index f9b6eb8b..adfecdb3 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldRemoveCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionHoldRemoveCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setDescription('Removes a retention hold UNSUPPORTED'); $this->addArgument('absPath', InputArgument::REQUIRED, 'Absolute path to node to which we want to remove a hold'); $this->addArgument('name', InputArgument::REQUIRED, 'Name of hold to remove'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Removes the specified hold from the node at absPath. The removal does not take effect until a save is performed. @@ -51,7 +52,9 @@ public function execute(InputInterface $input, OutputInterface $output) if (!isset($indexed[$name])) { throw new \Exception(sprintf( 'Unknown hold "%s" for node at path "%s", it currently has: %s', - $name, $absPath, implode(', ', array_keys($indexed)) + $name, + $absPath, + implode(', ', array_keys($indexed)) )); } diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionPolicyGetCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionPolicyGetCommand.php index 74ab5d15..4ca06546 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionPolicyGetCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionPolicyGetCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('retention:policy:get'); $this->setDescription('Get a retention policy for specified node UNSUPPORTED'); $this->addArgument('absPath', InputArgument::REQUIRED, 'Absolute path to node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Gets the retention policy of a node identified by its path. HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionPolicyRemoveCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionPolicyRemoveCommand.php index 15a42b7b..da7a614e 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/RetentionPolicyRemoveCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/RetentionPolicyRemoveCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('retention:policy:remove'); $this->setDescription('Remove a retention policy for specified node UNSUPPORTED'); $this->addArgument('absPath', InputArgument::REQUIRED, 'Absolute path to node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Removes the retention policy of a node identified by its path. HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionExportCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionExportCommand.php index b7158e60..e1684c5b 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionExportCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionExportCommand.php @@ -31,7 +31,8 @@ protected function configure() $this->addOption('skip-binary', null, InputOption::VALUE_NONE, 'Skip binary properties'); $this->addOption('document', null, InputOption::VALUE_NONE, 'Export the document view'); $this->addOption('pretty', null, InputOption::VALUE_NONE, 'Export in human readable format'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Export the node at the given path to the named XML file. By default the entire subgraph of the node will be exported unless the --no-recurse option diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionImpersonateCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionImpersonateCommand.php index 7d9164ed..e8073fc7 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionImpersonateCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionImpersonateCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('session:impersonate'); $this->setDescription('Impersonate the given user'); $this->addArgument('username', InputArgument::REQUIRED, 'Username of user to impersonate'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Note: This command is not implemented by any of the transports currently. Returns a new session in accordance with the specified (new) diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionImportCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionImportCommand.php index a34d713c..d5f1fcf8 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionImportCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionImportCommand.php @@ -34,7 +34,8 @@ protected function configure() $this->addArgument('parentAbsPath', InputArgument::REQUIRED, 'Path of node to export'); $this->addArgument('file', InputArgument::REQUIRED, 'File to import from'); $this->addOption('uuid-behavior', null, InputOption::VALUE_REQUIRED, 'UUID behavior', 'create-new'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Import the specified XML document into the current session as a child of the node specified by the parentAbsPath argument. @@ -95,7 +96,8 @@ public function execute(InputInterface $input, OutputInterface $output) if (!file_exists($file)) { throw new \InvalidArgumentException(sprintf( - 'The file "%s" does not exist', $file + 'The file "%s" does not exist', + $file )); } diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionInfoCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionInfoCommand.php index c69c37c9..e0ea54bc 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionInfoCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionInfoCommand.php @@ -22,7 +22,8 @@ protected function configure() { $this->setName('session:info'); $this->setDescription('Display information about current session'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' The command shows some basic information about the current session. HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionLoginCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionLoginCommand.php index 5f098ff9..e05b19df 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionLoginCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionLoginCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->addArgument('userId', InputArgument::REQUIRED, 'Unique identifier of user'); $this->addArgument('password', InputArgument::REQUIRED, 'Password'); $this->addArgument('workspaceName', InputArgument::OPTIONAL, 'Optional workspace name'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Login to a session. HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionLogoutCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionLogoutCommand.php index 91f7c17a..afb3e494 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionLogoutCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionLogoutCommand.php @@ -21,7 +21,8 @@ protected function configure() { $this->setName('session:logout'); $this->setDescription('Logout of the current session'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Releases all resources associated with this Session. This command should be called when a Session is no longer needed. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionNamespaceListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionNamespaceListCommand.php index 74c97848..844caa04 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionNamespaceListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionNamespaceListCommand.php @@ -22,7 +22,8 @@ protected function configure() { $this->setName('session:namespace:list'); $this->setDescription('List all namespace prefix to URI mappings in current session'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' List all namespace prefix to URI mappings in current session HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionNamespaceSetCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionNamespaceSetCommand.php index 61e42108..0e8d2b6f 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionNamespaceSetCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionNamespaceSetCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Set a namespace in the current session'); $this->addArgument('prefix', InputArgument::REQUIRED, 'The namespace prefix to be set as identifier'); $this->addArgument('uri', InputArgument::REQUIRED, 'The location of the namespace definition (usually a URI'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Sets the name of a namespace prefix. Within the scope of this Session, this method maps uri to prefix. The diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionRefreshCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionRefreshCommand.php index 12cdb316..2e177816 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionRefreshCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionRefreshCommand.php @@ -23,7 +23,8 @@ protected function configure() $this->setName('session:refresh'); $this->setDescription('Refresh the current session'); $this->addOption('keep-changes', null, InputOption::VALUE_NONE, 'Keep any changes that have been made in this session'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Reloads the current session. If the --keep-changes option is not given then this command discards diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/SessionSaveCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/SessionSaveCommand.php index 00b3d261..0ff5de36 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/SessionSaveCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/SessionSaveCommand.php @@ -21,7 +21,8 @@ protected function configure() { $this->setName('session:save'); $this->setDescription('Save the current session'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Validates all pending changes currently recorded in this Session. If validation of all pending changes succeeds, then this change diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckinCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckinCommand.php index 766121d3..807c517d 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckinCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckinCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('version:checkin'); $this->setDescription('Checkin (commit) a node version'); $this->addArgument('path', InputArgument::REQUIRED, 'Absolute path to node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Creates for the versionable node at path a new version with a system generated version name and returns that version (which will be the new base version of this node). Sets the jcr:checkedOut property to false @@ -52,7 +53,7 @@ protected function configure() If checkin succeeds, the change to the jcr:isCheckedOut property is dispatched immediately. HERE - ); + ); $this->requiresDescriptor(RepositoryInterface::OPTION_VERSIONING_SUPPORTED, true); } diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckoutCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckoutCommand.php index 74f609c4..0f7d4211 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckoutCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckoutCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('version:checkout'); $this->setDescription('Checkout a node version and enable changes to be made'); $this->addArgument('path', InputArgument::REQUIRED, 'Absolute path to node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Sets the versionable node at path to checked-out status by setting its jcr:isCheckedOut property to true. Under full versioning it also sets the jcr:predecessors property to be a reference to the current base diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckpointCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckpointCommand.php index 8c5e98e7..c907b219 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckpointCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/VersionCheckpointCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('version:checkpoint'); $this->setDescription('Checkin and then checkout a node'); $this->addArgument('path', InputArgument::REQUIRED, 'Path to node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Performs a version:checkin followed by a version:checkout on the versionable node at path diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/VersionHistoryCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/VersionHistoryCommand.php index 8689c957..66cad499 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/VersionHistoryCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/VersionHistoryCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setName('version:history'); $this->setDescription('Show version history of node at given absolute path'); $this->addArgument('path', InputArgument::REQUIRED, 'Absolute path to node'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Lists the version history of the node given at path. HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/VersionRemoveCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/VersionRemoveCommand.php index 5b0fcc56..e32fc7f1 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/VersionRemoveCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/VersionRemoveCommand.php @@ -25,7 +25,8 @@ protected function configure() $this->setDescription('Remove a node version'); $this->addArgument('path', InputArgument::REQUIRED, 'Path to node'); $this->addArgument('versionName', InputArgument::REQUIRED, 'Name of version to remove'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Removes the named version from this version history and automatically repairs the version graph. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/VersionRestoreCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/VersionRestoreCommand.php index 123cc9fd..77fb22d7 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/VersionRestoreCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/VersionRestoreCommand.php @@ -27,7 +27,8 @@ protected function configure() $this->addArgument('path', InputArgument::REQUIRED, 'Path to node'); $this->addArgument('versionName', InputArgument::REQUIRED, 'Name of version to retore'); $this->addOption('remove-existing', null, InputOption::VALUE_NONE, 'Flag that governs what happens in case of identifier collision'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Attempt to restore an old version of a node. The versionName should correspond to a version name as revealed by diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceCreateCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceCreateCommand.php index c07bab08..48c133c5 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceCreateCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceCreateCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Create a new workspace'); $this->addArgument('name', InputArgument::REQUIRED, 'Name of new workspace'); $this->addArgument('srcWorkspace', InputArgument::OPTIONAL, 'If specified, clone from this workspace'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Creates a new Workspace with the specified name. The new workspace is empty, meaning it contains only root node. diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceDeleteCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceDeleteCommand.php index 4a8862c9..d9f315c0 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceDeleteCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceDeleteCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Delete a workspace'); $this->addArgument('name', InputArgument::REQUIRED, 'Name of new workspace'); $this->addArgument('srcWorkspace', InputArgument::OPTIONAL, 'If specified, clone from this workspace'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Deletes the workspace with the specified name from the repository, deleting all content within it. HERE diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceListCommand.php index 650306da..8712dd8a 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceListCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setName('workspace:list'); $this->setDescription('Lists workspaces in the current repository'); $this->addArgument('srcWorkspace', InputArgument::OPTIONAL, 'If specified, clone from this workspace'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Lists the workspaces accessible to the current user. The current workspace is indicated by an asterix (*). diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceListCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceListCommand.php index 8cb0e71f..7afd24f3 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceListCommand.php @@ -22,7 +22,8 @@ protected function configure() { $this->setName('workspace:namespace:list'); $this->setDescription('List all namespace prefix to URI mappings in current workspace'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' List all namespace prefix to URI mappings in current workspace HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceRegisterCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceRegisterCommand.php index 1e9ad49a..fa5ed1f9 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceRegisterCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceRegisterCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Sets a one-to-one mapping between prefix and uri in the global namespace'); $this->addArgument('prefix', InputArgument::REQUIRED, 'The namespace prefix to be mapped'); $this->addArgument('uri', InputArgument::REQUIRED, 'The URI to be mapped'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' List all namespace prefix to URI mappings in current session HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceUnregisterCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceUnregisterCommand.php index b8363812..2dfc11e6 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceUnregisterCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceNamespaceUnregisterCommand.php @@ -23,7 +23,8 @@ protected function configure() $this->setName('workspace:namespace:unregister'); $this->setDescription('Unregister a namespace'); $this->addArgument('uri', InputArgument::REQUIRED, 'The URI to be removed'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Removes the specified namespace URI from namespace registry. The following restrictions apply: diff --git a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceUseCommand.php b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceUseCommand.php index 54dd8866..f16e1550 100644 --- a/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceUseCommand.php +++ b/src/PHPCR/Shell/Console/Command/Phpcr/WorkspaceUseCommand.php @@ -24,7 +24,8 @@ protected function configure() $this->setDescription('Change the current workspace'); $this->addArgument('name', InputArgument::REQUIRED, 'Name of workspace to use'); $this->addArgument('srcWorkspace', InputArgument::OPTIONAL, 'If specified, clone from this workspace'); - $this->setHelp(<<<'HERE' + $this->setHelp( + <<<'HERE' Change the workspace. HERE ); diff --git a/src/PHPCR/Shell/Console/Command/Shell/AliasListCommand.php b/src/PHPCR/Shell/Console/Command/Shell/AliasListCommand.php index c09b2a5d..1e9e7564 100644 --- a/src/PHPCR/Shell/Console/Command/Shell/AliasListCommand.php +++ b/src/PHPCR/Shell/Console/Command/Shell/AliasListCommand.php @@ -23,7 +23,8 @@ public function configure() { $this->setName('shell:alias:list'); $this->setDescription('List all the registered aliases'); - $this->setHelp(<<<'EOT' + $this->setHelp( + <<<'EOT' List the aliases as defined in ~/.phpcrsh/aliases.yml. EOT ); diff --git a/src/PHPCR/Shell/Console/Command/Shell/ClearCommand.php b/src/PHPCR/Shell/Console/Command/Shell/ClearCommand.php index 10debe72..114d7e55 100644 --- a/src/PHPCR/Shell/Console/Command/Shell/ClearCommand.php +++ b/src/PHPCR/Shell/Console/Command/Shell/ClearCommand.php @@ -22,7 +22,8 @@ public function configure() { $this->setName('shell:clear'); $this->setDescription('Clear the screen'); - $this->setHelp(<<<'EOT' + $this->setHelp( + <<<'EOT' Clear the screen EOT ); diff --git a/src/PHPCR/Shell/Console/Command/Shell/ConfigInitCommand.php b/src/PHPCR/Shell/Console/Command/Shell/ConfigInitCommand.php index c042e543..8da9c7d4 100644 --- a/src/PHPCR/Shell/Console/Command/Shell/ConfigInitCommand.php +++ b/src/PHPCR/Shell/Console/Command/Shell/ConfigInitCommand.php @@ -24,7 +24,8 @@ public function configure() { $this->setName('shell:config:init'); $this->setDescription('Initialize a local configuration with default values'); - $this->setHelp(<<<'EOT' + $this->setHelp( + <<<'EOT' Initialize a new configuration folder, .phpcrsh in the users HOME directory. EOT ); diff --git a/src/PHPCR/Shell/Console/Command/Shell/ConfigReloadCommand.php b/src/PHPCR/Shell/Console/Command/Shell/ConfigReloadCommand.php index 189c9161..06c3f30a 100644 --- a/src/PHPCR/Shell/Console/Command/Shell/ConfigReloadCommand.php +++ b/src/PHPCR/Shell/Console/Command/Shell/ConfigReloadCommand.php @@ -24,7 +24,8 @@ public function configure() { $this->setName('shell:config:reload'); $this->setDescription('Reload the configuration'); - $this->setHelp(<<<'EOT' + $this->setHelp( + <<<'EOT' Reload the configuration EOT ); diff --git a/src/PHPCR/Shell/Console/Command/Shell/ProfileShowCommand.php b/src/PHPCR/Shell/Console/Command/Shell/ProfileShowCommand.php index 3efb4bf2..0bdcb2c2 100644 --- a/src/PHPCR/Shell/Console/Command/Shell/ProfileShowCommand.php +++ b/src/PHPCR/Shell/Console/Command/Shell/ProfileShowCommand.php @@ -25,7 +25,8 @@ public function configure() { $this->setName('shell:profile:show'); $this->setDescription('Show the current profile configuration'); - $this->setHelp(<<<'EOT' + $this->setHelp( + <<<'EOT' Display the currently loaded profile configuration EOT ); diff --git a/src/PHPCR/Shell/Console/Helper/NodeHelper.php b/src/PHPCR/Shell/Console/Helper/NodeHelper.php index 6a12d8c2..b26199e6 100644 --- a/src/PHPCR/Shell/Console/Helper/NodeHelper.php +++ b/src/PHPCR/Shell/Console/Helper/NodeHelper.php @@ -39,7 +39,8 @@ public function assertNodeIsVersionable(NodeInterface $node) { if (!$this->nodeHasMixinType($node, 'mix:versionable')) { throw new \OutOfBoundsException(sprintf( - 'Node "%s" is not versionable', $node->getPath() + 'Node "%s" is not versionable', + $node->getPath() )); } } diff --git a/src/PHPCR/Shell/Console/Helper/ResultFormatterHelper.php b/src/PHPCR/Shell/Console/Helper/ResultFormatterHelper.php index a2b9092b..b6cd225c 100644 --- a/src/PHPCR/Shell/Console/Helper/ResultFormatterHelper.php +++ b/src/PHPCR/Shell/Console/Helper/ResultFormatterHelper.php @@ -90,10 +90,12 @@ public function formatQueryResult(QueryResultInterface $result, OutputInterface $table->render($output); if (true === $this->config['show_execution_time_query']) { - $output->writeln(sprintf( + $output->writeln( + sprintf( '%s rows in set (%s sec)', count($result->getRows()), - number_format($elapsed, $this->config['execution_time_expansion'])) + number_format($elapsed, $this->config['execution_time_expansion']) + ) ); } } @@ -169,7 +171,8 @@ public function formatNodePropertiesInline(NodeInterface $node) $out = []; foreach ($node->getProperties() as $property) { - $out[] = sprintf('%s: %s', + $out[] = sprintf( + '%s: %s', $property->getName(), $this->formatValue($property) ); diff --git a/src/PHPCR/Shell/Console/Helper/TextHelper.php b/src/PHPCR/Shell/Console/Helper/TextHelper.php index 007ec0a7..6ca9945c 100644 --- a/src/PHPCR/Shell/Console/Helper/TextHelper.php +++ b/src/PHPCR/Shell/Console/Helper/TextHelper.php @@ -65,7 +65,8 @@ public function truncate($string, $length = null, $alignment = null, $delimStrin if ($delimLen > $length) { throw new \InvalidArgumentException(sprintf( 'Delimiter length "%s" cannot be greater than truncate length "%s"', - $delimLen, $length + $delimLen, + $length )); } @@ -74,7 +75,8 @@ public function truncate($string, $length = null, $alignment = null, $delimStrin if ('left' === $alignment) { $string = substr($string, 0, $offset).$delimString; } else { - $string = $delimString.substr($string, + $string = $delimString.substr( + $string, strlen($string) - $offset ); } diff --git a/src/PHPCR/Shell/Query/FunctionOperand.php b/src/PHPCR/Shell/Query/FunctionOperand.php index 4eaf7bc7..c2e324ec 100644 --- a/src/PHPCR/Shell/Query/FunctionOperand.php +++ b/src/PHPCR/Shell/Query/FunctionOperand.php @@ -63,7 +63,8 @@ public function execute($functionMap, $row) $functionName = $this->getFunctionName(); if (!isset($functionMap[$functionName])) { - throw new InvalidQueryException(sprintf('Unknown function "%s", known functions are "%s"', + throw new InvalidQueryException(sprintf( + 'Unknown function "%s", known functions are "%s"', $functionName, implode(', ', array_keys($functionMap)) )); diff --git a/src/PHPCR/Shell/Serializer/NodeNormalizer.php b/src/PHPCR/Shell/Serializer/NodeNormalizer.php index 07c0534a..429cf7c3 100644 --- a/src/PHPCR/Shell/Serializer/NodeNormalizer.php +++ b/src/PHPCR/Shell/Serializer/NodeNormalizer.php @@ -203,7 +203,8 @@ private function isPropertyEditable(PropertyInterface $property) // do not serialize binary objects if (false === $this->allowBinary && PropertyType::BINARY == $property->getType()) { $this->notes[] = sprintf( - 'Binary property "%s" has been omitted', $property->getName() + 'Binary property "%s" has been omitted', + $property->getName() ); return false; diff --git a/src/PHPCR/Shell/Subscriber/ProfileFromSessionInputSubscriber.php b/src/PHPCR/Shell/Subscriber/ProfileFromSessionInputSubscriber.php index f018805e..822590cd 100644 --- a/src/PHPCR/Shell/Subscriber/ProfileFromSessionInputSubscriber.php +++ b/src/PHPCR/Shell/Subscriber/ProfileFromSessionInputSubscriber.php @@ -60,7 +60,9 @@ public function handleProfileInit(ProfileInitEvent $e) case 'db-path': if (!file_exists($value)) { throw new \InvalidArgumentException(sprintf( - 'DB file "%s" does not exist.', $value)); + 'DB file "%s" does not exist.', + $value + )); } $value = realpath(dirname($value)).DIRECTORY_SEPARATOR.basename($value); diff --git a/src/PHPCR/Shell/Subscriber/ProfileLoaderSubscriber.php b/src/PHPCR/Shell/Subscriber/ProfileLoaderSubscriber.php index 04579780..a3f3b162 100644 --- a/src/PHPCR/Shell/Subscriber/ProfileLoaderSubscriber.php +++ b/src/PHPCR/Shell/Subscriber/ProfileLoaderSubscriber.php @@ -57,7 +57,8 @@ public function handleProfileInit(ProfileInitEvent $e) if (count($profileNames) === 0) { $output->writeln('No transport specified, and no profiles available.'); - $output->writeln(<<<'EOT' + $output->writeln( + <<<'EOT' You must specify the connection parameters, for example: diff --git a/tests/PHPCR/Shell/Helper/EditorHelperTest.php b/tests/PHPCR/Shell/Helper/EditorHelperTest.php index 67a81cee..ce9e106f 100644 --- a/tests/PHPCR/Shell/Helper/EditorHelperTest.php +++ b/tests/PHPCR/Shell/Helper/EditorHelperTest.php @@ -26,19 +26,22 @@ public function setUp(): void public function testFromValue() { - $res = $this->helper->fromString(<<<'EOT' + $res = $this->helper->fromString( + <<<'EOT' One Two Three EOT ); - $this->assertEquals(<<<'EOT' + $this->assertEquals( + <<<'EOT' One Two Three EOT - , $res + , + $res ); }