Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,29 @@ A tool to manage your PHP School workshops. Search, install, update & remove wor

## Installation

### Phar

This is the recommended installation method.

```
curl https://php-school.github.io/workshop-manager/workshop-manager.phar
mv workshop-manager.phar /usr/local/bin/workshop-manager
chmod +x /usr/local/bin/workshop-manager
workshop-manager verify
```

### Composer

If you install the workshop-manager via composer you will need to make sure that you don't have conflicting dependencies
with other globally installed tools. Also you will need to be able to use the self-update and rollback commands.

You will need to make sure that your composer global bin directory is available in your $PATH environment variable.

```
composer global require php-school/workshop-manager
workshop-manager verify
```

This snippet downloads the phar package (an executable PHP package) and moves it to a common install directory, makes it executable and then runs the workshop manager's verify command. You should see some green success messages if everything went will.


Expand Down
12 changes: 8 additions & 4 deletions app/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,14 @@
->setDescription('Search for a PHP School workshop.');
$application->command('installed', ListWorkshops::class, ['show'])
->setDescription('List installed PHP School workshops.');
$application->command('self-update', SelfUpdate::class)
->setDescription('Update the workshop manager to the latest version.');
$application->command('rollback', SelfRollback::class)
->setDescription('Rollback the workshop manager to the previous version.');

if (extension_loaded('phar') && Phar::running()) {
$application->command('self-update', SelfUpdate::class)
->setDescription('Update the workshop manager to the latest version.');
$application->command('rollback', SelfRollback::class)
->setDescription('Rollback the workshop manager to the previous version.');
}

$application->command('verify', VerifyInstall::class, ['validate'])
->descriptions('Verify your installation is working correctly');

Expand Down