1. Go to this page and download the library: Download sagor/github-updater library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
mermaid
flowchart TD
subgraph Triggers ["Deployment Triggers"]
A["🌐 Web Request: GET /github-pull"]
B["💻 CLI Command: php artisan github:pull"]
end
subgraph Package ["GithubUpdater Core Engine"]
C{"Router / Controller"}
D{"Console Handler"}
E["Load Configuration<br/>(config/github-updater.php)"]
F["Build Git URL with PAT Token<br/>(https://user:[email protected])"]
G["Run 'git pull' Subprocess"]
H["Parse ARTISAN_COMMANDS Pipeline"]
I["Execute Chained Artisan Commands"]
end
subgraph Outputs ["Execution Feedback"]
J["🖥️ Streamed Web Terminal UI"]
K["📋 Console Log Output"]
end
A --> C
B --> D
C --> E
D --> E
E --> F
F --> G
G --> H
H --> I
I -->|Web Output| J
I -->|CLI Output| K