From 59e48c89256647119d2f7f028028b2e1e6a0b621 Mon Sep 17 00:00:00 2001 From: stovak <119924+stovak@users.noreply.github.com> Date: Mon, 14 Jun 2021 21:50:15 -0700 Subject: [PATCH] commit and push command moved to local group --- src/Commands/D9ify/CommitAndPushCommand.php | 139 -------------------- 1 file changed, 139 deletions(-) delete mode 100644 src/Commands/D9ify/CommitAndPushCommand.php diff --git a/src/Commands/D9ify/CommitAndPushCommand.php b/src/Commands/D9ify/CommitAndPushCommand.php deleted file mode 100644 index ef8974d3a..000000000 --- a/src/Commands/D9ify/CommitAndPushCommand.php +++ /dev/null @@ -1,139 +0,0 @@ -setDestinationDirectory( - Directory::factory( - $this->input()->getArgument('destination') ?? - $this->sourceDirectory->getSiteInfo()->getName() . "-" . date('Y'), - $this->output(), - ) - ); - $this->restoreDatabaseToDestinationSite(); - $this->unpackSiteFilesAndRsyncToDestination(); - $this->checkinVersionManagedFilesAndPush(); - } - - - /** - * @step TODO: unpack site files archive and rsync them up. - * @description - * There's a hard limit to the size archive you can upload. We'll do an rysnc - * but if/when it times out, we need a way of restarting the rsync. - * - */ - public function unpackSiteFilesAndRsyncToDestination(OutputInterface $output) - { - $output->writeln("===> TODO: unpack files archive and rsync to destination"); - } - - /** - * @step TODO: check in the version-managed files - * @description - * Push them up to dev environment. - * - */ - public function checkinVersionManagedFilesAndPush(OutputInterface $output) - { - $output->writeln("===> Restore database to destination: "); - $getMysqlCommand = sprintf( - "terminus connection:info %s.dev --field=mysql_command", - $this->getDestinationDirectory()->getSiteInfo()->getName() - ); - // terminus connection:set hivinsite-2021.dev git - // cd local-copies/hivinsite - // git add * - // git commit -m 'd9ify conversion' - - $output->writeln("===> TODO: Check-in Version-managed files and push."); - } - - /** - * @return Directory - */ - public function getDestinationDirectory(): Directory - { - return $this->destinationDirectory; - } - - /** - * @step Set Destination directory - * @description - * Destination name will be {source}-{THIS YEAR} by default - * if you don't provide a value. - * - * @param Directory $destinationDirectory - */ - public function setDestinationDirectory(Directory $destinationDirectory): void - { - $this->destinationDirectory = $destinationDirectory; - } -}