You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The CLI test dependencies install into `tests/vendor/`, leaving the main application `vendor/` directory unchanged.
52
52
53
+
On Windows PowerShell, set the Composer config and run the same suite with:
54
+
55
+
```powershell
56
+
Set-Location tests
57
+
$env:COMPOSER = 'composer.cli-tests.json'
58
+
composer install
59
+
Set-Location ..
60
+
php tests/vendor/bin/phpunit -c phpunit.xml.dist
61
+
```
62
+
63
+
Sandbox CLI or web UI changes must remain compatible with macOS, Linux, and native Windows. Before submitting such changes, run:
64
+
65
+
```bash
66
+
php bin/qi doctor
67
+
php bin/qi help
68
+
```
69
+
70
+
On Windows, also smoke-test both supplied launchers:
71
+
72
+
```powershell
73
+
.\bin\qi.ps1 help
74
+
.\bin\qi.cmd help
75
+
```
76
+
77
+
Windows-specific changes should cover drive-letter paths, paths containing spaces, Command Prompt and PowerShell execution, and the `ui:start`/`ui:status`/`ui:stop` lifecycle. GitHub Actions runs the PHPUnit suite and launcher smoke tests on native Windows.
78
+
53
79
## :computer: Make something great
54
80
55
81
1. Create a new branch in your repository before doing any work. It should be based off the `develop` branch:
phpBB boards require a web server running PHP and one of the following database management systems.
@@ -59,13 +59,28 @@ phpBB boards require a web server running PHP and one of the following database
59
59
60
60
## QuickInstall CLI
61
61
62
-
QuickInstall now includes a Docker-based CLI for creating local phpBB test boards. It writes generated state to `.qi/` and leaves the legacy web UI unchanged. The QuickInstall CLI requires PHP 8.0 or newer for the `php bin/qi` command.
62
+
QuickInstall now includes a cross-platform, Docker-based CLI and local sandbox web UI for creating phpBB test boards. They work on macOS, Linux, and native Windows and write generated state to `.qi/` without changing the legacy web application.
The examples use `php bin/qi`, which works on every supported operating system when PHP is in `PATH`. Windows users can alternatively use the supplied PowerShell or Command Prompt launchers:
78
+
79
+
```powershell
80
+
.\bin\qi.ps1 board:list
81
+
.\bin\qi.cmd board:list
82
+
```
83
+
69
84
The QuickInstall CLI targets phpBB 3.2+ installer-based boards. phpBB 3.0/3.1 remain legacy-web-app territory and are not planned for the QuickInstall CLI.
70
85
71
86
Downloaded extensions can be unzipped into `customisations/` and mounted into boards:
Copy file name to clipboardExpand all lines: docs/sandbox-cli.md
+74-11Lines changed: 74 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -60,6 +60,32 @@ Then open the URL printed by the command:
60
60
http://127.0.0.1:8079/
61
61
```
62
62
63
+
## Commands by OS
64
+
65
+
The examples in this guide use the portable command form:
66
+
67
+
```bash
68
+
php bin/qi <command>
69
+
```
70
+
71
+
It works on macOS, Linux, and Windows when PHP is available in `PATH`.
72
+
73
+
Native Windows launchers are also included. From PowerShell:
74
+
75
+
```powershell
76
+
.\bin\qi.ps1 <command>
77
+
```
78
+
79
+
From Command Prompt:
80
+
81
+
```batch
82
+
bin\qi.cmd <command>
83
+
```
84
+
85
+
Arguments and options are identical with every launcher. Run commands from the QuickInstall project root. Windows drive-letter paths, UNC paths, backslashes, spaces, and case-insensitive filesystem paths are supported.
86
+
87
+
Docker Desktop on Windows must use its WSL 2 or Hyper-V Linux-container backend rather than Windows containers.
88
+
63
89
## Common Recipes
64
90
65
91
Create a small empty board:
@@ -219,6 +245,12 @@ By default, extension sources must live under `customisations/`. To mount a trus
QuickInstall includes a local browser UI for the same sandbox workflows exposed by the CLI. It is served by PHP's built-in web server and backed by the same `.qi/` project state.
386
+
QuickInstall includes a local browser UI for the same sandbox workflows exposed by the CLI. It is served by PHP's built-in web server and backed by the same `.qi/` project state. The UI server can be started, checked, restarted, and stopped on macOS, Linux, or native Windows.
|`.qi/runtime/ui.json`| Tracked web UI server state |
438
+
|`.qi/runtime/ui.log`| Web UI server output log |
439
+
|`.qi/runtime/ui.log.err`| Windows web UI server error log |
440
+
|`.qi/cache/`| Cached update-check metadata |
402
441
403
442
User-managed drop zone:
404
443
@@ -419,10 +458,34 @@ customisations/
419
458
420
459
## Troubleshooting
421
460
461
+
If QuickInstall is not working as expected, start with the environment check:
462
+
463
+
```bash
464
+
php bin/qi doctor
465
+
```
466
+
467
+
Every check should report `OK`; failures include the detected problem. On Windows, use `.\bin\qi.ps1 doctor` or `bin\qi.cmd doctor`.
468
+
469
+
#### Command is not found on Windows
470
+
471
+
Run QuickInstall from the project root with one of the supplied launchers:
472
+
473
+
```powershell
474
+
.\bin\qi.ps1 help
475
+
```
476
+
477
+
```batch
478
+
bin\qi.cmd help
479
+
```
480
+
481
+
If either launcher reports that `php` is not recognized, install PHP 8 or newer and add its directory to the Windows `PATH`. Open a new terminal and run `php --version` to confirm it is available.
482
+
422
483
#### Docker command fails
423
484
424
485
Check that Docker Desktop is running and that the docker command works in this terminal.
425
486
487
+
On Windows, also confirm Docker Desktop is using Linux containers. `php bin/qi doctor` reports `Linux containers: OK` when configured correctly.
488
+
426
489
#### Composer command fails
427
490
428
491
QuickInstall uses composer from PATH first, then `composer.phar` from the project root. Restore `composer.phar` or install Composer if both are missing.
@@ -466,4 +529,4 @@ If the selected port is already in use, choose a different local port:
466
529
php bin/qi ui:start --port 8088
467
530
```
468
531
469
-
The UI server log is written to `.qi/runtime/ui.log`.
532
+
The UI server output log is written to `.qi/runtime/ui.log`. On Windows, PHP server errors are written to `.qi/runtime/ui.log.err`.
@@ -417,6 +439,14 @@ private function supportsAnsi(): bool
417
439
{
418
440
returnposix_isatty(STDOUT);
419
441
}
442
+
if (function_exists('stream_isatty') && defined('STDOUT') && !stream_isatty(STDOUT))
443
+
{
444
+
returnfalse;
445
+
}
446
+
if (PHP_OS_FAMILY === 'Windows' && function_exists('sapi_windows_vt100_support') && defined('STDOUT'))
447
+
{
448
+
returnsapi_windows_vt100_support(STDOUT);
449
+
}
420
450
421
451
returnPHP_SAPI === 'cli';
422
452
}
@@ -897,6 +927,17 @@ private function printHelpRows(array $rows): void
897
927
privatefunctionhelpCommands(): array
898
928
{
899
929
return [
930
+
'Setup commands' => [
931
+
'doctor' => [
932
+
'title' => 'doctor',
933
+
'usage' => 'doctor',
934
+
'summary' => 'Check local PHP, Docker, Git, and Composer requirements.',
935
+
'description' => 'Checks that required host tools are available, Docker Desktop is running, Docker Compose works, and Docker is using Linux containers.',
0 commit comments