Skip to content

oops

oops #3

Workflow file for this run

name: Build
on:
push:
branches:
- master
jobs:
phpstan:
name: PHPStan Analysis
runs-on: ubuntu-latest
steps:
- name: Startup
uses: actions/checkout@v3
- name: Download PHP Release
uses: dsaltares/[email protected]
with:
file: PHP-8.3-Linux-x86_64-PM5.tar.gz
repo: pmmp/PHP-Binaries
version: "tags/pm5-php-8.3-latest"
- name: Unpack PHP Release
run: tar -xzvf PHP-8.3-Linux-x86_64-PM5.tar.gz
- name: Download Composer
run: curl -o composer.phar "https://getcomposer.org/composer-stable.phar"
- name: Config Composer
run: ./bin/php7/bin/php composer.phar config -g github-oauth.github.com ${{ secrets.GITHUB_TOKEN }}
- name: Install Composer dependencies
run: ./bin/php7/bin/php composer.phar install --prefer-dist --no-interaction --ignore-platform-req=ext-iconv
- name: Run PHPStan
run: ./bin/php7/bin/php vendor/bin/phpstan.phar analyze --no-progress
build:
name: Build
runs-on: ubuntu-latest
needs: phpstan
steps:
- name: Startup
uses: actions/checkout@v3
- name: Download PHP Release
uses: dsaltares/[email protected]
with:
file: PHP-8.3-Linux-x86_64-PM5.tar.gz
repo: pmmp/PHP-Binaries
version: "tags/pm5-php-8.3-latest"
- name: Unpack PHP Release
run: tar -xzvf PHP-8.3-Linux-x86_64-PM5.tar.gz
- name: Download Composer
run: curl -o composer.phar "https://getcomposer.org/composer-stable.phar"
- name: Config Composer
run: ./bin/php7/bin/php composer.phar config -g github-oauth.github.com ${{ secrets.GITHUB_TOKEN }}
- name: Install Composer dependencies
run: ./bin/php7/bin/php composer.phar install --prefer-dist --no-interaction --ignore-platform-req=ext-iconv
- name: Run Build
run: ./bin/php7/bin/php -dphar.readonly=0 vendor/bin/pharynx -i . -c -p=DisableLocatorBar.phar
- name: Get plugin.yml information
run: |
name=$(grep -oP '(?<=name: ).*' plugin.yml || echo "unknown")
version=$(grep -oP '(?<=version: ).*' plugin.yml || echo "unknown")
echo "Name of plugin: $name"
echo "Version of plugin: $version"
echo "PLUGIN_NAME=$name" >> $GITHUB_ENV
echo "PLUGIN_VERSION=$version" >> $GITHUB_ENV
- name: Create Release
uses: ncipollo/[email protected]
with:
artifacts: ${{ github.workspace }}/DisableLocatorBar.phar
draft: false
name: ${{ env.PLUGIN_NAME }} v${{ env.PLUGIN_VERSION }} Release
tag: v${{ env.PLUGIN_VERSION }}
token: ${{ secrets.GITHUB_TOKEN }}
body: "The artifacts are kept up to date with the master branch"
commit: ${{ github.sha }}
allowUpdates: true
removeArtifacts: true
replacesArtifacts: true