From c340660084634eba34d0f7a381b2c8cf8b7d71c8 Mon Sep 17 00:00:00 2001 From: Mark Hamstra Date: Tue, 12 Oct 2021 02:51:14 +0200 Subject: [PATCH] Move + lowercase the gitify binary --- README.md | 12 ++++++++---- application.php | 4 ++-- Gitify => bin/gitify | 2 +- Gitify.cmd => bin/gitify.cmd | 0 composer.json | 2 +- src/Command/BackupCommand.php | 2 +- src/Command/InstallPackageCommand.php | 2 +- src/Command/RestoreCommand.php | 4 ++-- 8 files changed, 16 insertions(+), 12 deletions(-) rename Gitify => bin/gitify (85%) mode change 100755 => 100644 rename Gitify.cmd => bin/gitify.cmd (100%) diff --git a/README.md b/README.md index c7e0e5a..097143e 100644 --- a/README.md +++ b/README.md @@ -11,14 +11,18 @@ Gitify v2 brings updated dependencies, additional functionality, and easier inst The data file structure is unchanged, so you can safely update to v2. -1. To upgrade **with the intention of contributing to Gitify**, you can keep your installation. Bring it up to date with the master branch (`git fetch origin && git reset --hard origin/master`, or `git fetch upstream && git reset --hard upstream/master`), install the updated dependencies (`composer install`), and you're ready to go. You'll need to repeat these steps to upgrade to newer versions. -2. To upgrade **simply to use Gitify**, it's recommended to remove the v1 git-based installation complete, and instead install Gitify globally with Composer as described in the installation below. +1. To upgrade **with the intention of contributing to Gitify**, you can keep your exiting git installation. + 1. Bring it up to date with the master branch (`git fetch origin && git reset --hard origin/master`, or `git fetch upstream && git reset --hard upstream/master`) + 2. Install updated dependencies (`composer install`) + 3. Update your `$PATH` to point to the `bin` directory. This may be in your `~/.bash_profile` or `~/.zshrc` file. +2. To upgrade **simply to use Gitify**, it's recommended to remove the v1 git-based installation completely, and instead install Gitify globally with Composer as described in the installation section below. **Important to know:** - Gitify v2 is not yet compatible with Gitify Watch. This will be restored in a future update of Gitify Watch. - The minimum PHP version has been increased to 7.2.5. - Documentation has not yet been updated for v2. This will happen soon. +- `Gitify` has changed to `gitify` and is now in a /bin subdirectory. ## Installation @@ -26,7 +30,7 @@ The data file structure is unchanged, so you can safely update to v2. composer global require modmore/gitify:^2 ```` -If that does not make gitify available on your path, add the output of `composer global config bin-dir --absolute` to your path (i.e. in the `~/.bash_profile` or `~/.zshrc` file on Mac/Linux). +If that does not make `gitify` available on your path, add the output of `composer global config bin-dir --absolute` to your path (i.e. in the `~/.bash_profile` or `~/.zshrc` file on Mac/Linux). To update, use `composer global update modmore/gitify`. @@ -40,7 +44,7 @@ Use the manual installation to build from source, useful if you intend to help m $ git clone https://github.com/modmore/Gitify.git Gitify $ cd Gitify $ composer install --no-dev -$ chmod +x Gitify +$ chmod +x gitify ```` Please see [the Installation documentation](https://docs.modmore.com/en/Open_Source/Gitify/Installation/index.html) for more details. diff --git a/application.php b/application.php index 7216244..47fb393 100644 --- a/application.php +++ b/application.php @@ -87,7 +87,7 @@ $application->add(new RestoreCommand); $application->add(new ClearCacheCommand); /** - * We return it so the CLI controller in /Gitify can run it, or for other integrations to - * work with the Gitify api directly. + * We return it so the CLI controller in /bin/gitify can run it, or for other integrations to + * work with the gitify api directly. */ return $application; diff --git a/Gitify b/bin/gitify old mode 100755 new mode 100644 similarity index 85% rename from Gitify rename to bin/gitify index c1ce889..baa383b --- a/Gitify +++ b/bin/gitify @@ -12,5 +12,5 @@ use modmore\Gitify\Gitify; -$application = include dirname(__FILE__) . '/application.php'; +$application = include dirname(__DIR__) . '/application.php'; $application->run(); \ No newline at end of file diff --git a/Gitify.cmd b/bin/gitify.cmd similarity index 100% rename from Gitify.cmd rename to bin/gitify.cmd diff --git a/composer.json b/composer.json index 13332d4..910f0b9 100644 --- a/composer.json +++ b/composer.json @@ -14,6 +14,6 @@ } }, "bin": [ - "Gitify" + "bin/gitify" ] } diff --git a/src/Command/BackupCommand.php b/src/Command/BackupCommand.php index 749fa4a..5de3cf0 100755 --- a/src/Command/BackupCommand.php +++ b/src/Command/BackupCommand.php @@ -27,7 +27,7 @@ protected function configure() { $this ->setName('backup') - ->setDescription('Creates a quick backup of the entire MODX database. Runs automatically when using `Gitify build --force`, but can also be used manually.') + ->setDescription('Creates a quick backup of the entire MODX database. Runs automatically when using `gitify build --force`, but can also be used manually.') ->addArgument( 'name', InputArgument::OPTIONAL, diff --git a/src/Command/InstallPackageCommand.php b/src/Command/InstallPackageCommand.php index 165e772..c0fb1d6 100644 --- a/src/Command/InstallPackageCommand.php +++ b/src/Command/InstallPackageCommand.php @@ -13,7 +13,7 @@ * * Installs a package * - * @package modmore\Gitify\Command + * @package modmore\gitify\Command */ class InstallPackageCommand extends BaseCommand { diff --git a/src/Command/RestoreCommand.php b/src/Command/RestoreCommand.php index 72f63fb..2faa714 100644 --- a/src/Command/RestoreCommand.php +++ b/src/Command/RestoreCommand.php @@ -15,7 +15,7 @@ /** * Class RestoreCommand * - * Used for restoring database backups created with `Gitify backup` (or possibly any other type of mysql backup). + * Used for restoring database backups created with `gitify backup` (or possibly any other type of mysql backup). * * @package modmore\Gitify\Command */ @@ -28,7 +28,7 @@ protected function configure() { $this ->setName('restore') - ->setDescription('Restores the MODX database from a database dump created by `Gitify backup`') + ->setDescription('Restores the MODX database from a database dump created by `gitify backup`') ->addArgument( 'file',