diff --git a/.github/workflows/continuous-integration.yml b/.github/workflows/continuous-integration.yml index 46887f00..07185e33 100644 --- a/.github/workflows/continuous-integration.yml +++ b/.github/workflows/continuous-integration.yml @@ -96,31 +96,4 @@ jobs: - unit-tests - coding-standards - static-analysis - runs-on: ${{ matrix.operating-system }} - strategy: - matrix: - operating-system: - - ubuntu-latest - php-versions: - - '8.1' - steps: - - name: Setup PHP - uses: shivammathur/setup-php@v2 - with: - coverage: none - tools: composer, box - php-version: "${{ matrix.php-version }}" - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - # Temporary until we have a first tag; Box needs at least one tag to exist! - - run: git describe --tags HEAD || git tag 0.0.0 - - uses: ramsey/composer-install@v3 - - name: Build PHAR - run: box compile - - name: Check the PHAR executes - run: php pie.phar --version - - uses: actions/upload-artifact@v4 - with: - name: pie-${{ github.sha }}.phar - path: pie.phar + uses: ./.github/workflows/release-unsigned-phar.yml diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 3f7488ba..b0c33be3 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -21,14 +21,25 @@ concurrency: cancel-in-progress: false jobs: + build-phar: + uses: ./.github/workflows/release-unsigned-phar.yml + # Build job build: runs-on: ubuntu-latest + needs: + - build-phar steps: - name: Checkout uses: actions/checkout@v4 - name: Build documentation run: .github/docs/build-docs.sh + - name: Fetch built PHAR from artifacts + uses: actions/download-artifact@v4 + with: + name: pie-${{ github.sha }}.phar + - name: Copy PHAR into docs + run: cp pie.phar docs-package/pie-nightly.phar - name: Upload artifact uses: actions/upload-pages-artifact@v3 with: diff --git a/.github/workflows/release-unsigned-phar.yml b/.github/workflows/release-unsigned-phar.yml new file mode 100644 index 00000000..7cffb9b4 --- /dev/null +++ b/.github/workflows/release-unsigned-phar.yml @@ -0,0 +1,36 @@ +name: "Release unsigned PHAR" + +on: + workflow_call: + +jobs: + + build-phar: + runs-on: ${{ matrix.operating-system }} + strategy: + matrix: + operating-system: + - ubuntu-latest + php-versions: + - '8.1' + steps: + - name: Setup PHP + uses: shivammathur/setup-php@v2 + with: + coverage: none + tools: composer, box + php-version: "${{ matrix.php-version }}" + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + # Temporary until we have a first tag; Box needs at least one tag to exist! + - run: git describe --tags HEAD || git tag 0.0.0 + - uses: ramsey/composer-install@v3 + - name: Build PHAR + run: box compile + - name: Check the PHAR executes + run: php pie.phar --version + - uses: actions/upload-artifact@v4 + with: + name: pie-${{ github.sha }}.phar + path: pie.phar diff --git a/README.md b/README.md index 1432bf83..799553ba 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,9 @@ please read [extension-maintainers](./docs/extension-maintainers.md). ### Manual installation -- Download `pie.phar` from the [latest releases](https://github.com/php/pie/releases) +- Download `pie.phar` either: + - [latest stable release](https://github.com/php/pie/releases) + - [latest unstable nightly](https://php.github.io/pie/pie-nightly.phar) - Validate the signature in `pie.phar.asc` - You may then invoke PIE with `php pie.phar `