now your deploy script is ready add to this file this script and you can custom it as you like
#!/bin/bashset-eecho"Deployment started ..."# Enter maintenance mode or return true# if already is in maintenance mode(phpartisandown) ||true# Pull the latest version of the appgitreset--hardgitpulloriginmaster# Install composer dependenciescomposerinstall--no-dev--no-interaction--prefer-dist--optimize-autoloader# Clear the old cachephpartisanclear-compiled# Recreate cachephpartisanoptimize# Compile npm assetsyarnyarnbuild# Run database migrationsphpartisanmigrate--force# Exit maintenance modephpartisanupecho"Deployment finished!"
now push all of these updates to your GitHub repo and you will find on the Actions tab that the action is run and after that, you will find the updates on your server.