Combined workflows, Screw this noise
Update build-all.yml, php-render.yml, and sass-compile.yml
This commit is contained in:
parent
bed09c3b2a
commit
0673916f5e
@ -1,4 +1,4 @@
|
||||
name: Compile SASS
|
||||
name: Build Everything
|
||||
|
||||
on:
|
||||
push:
|
||||
@ -21,6 +21,12 @@ jobs:
|
||||
submodules: true
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Setup PHP
|
||||
uses: shivammathur/setup-php@v2
|
||||
with:
|
||||
php-version: '8.4'
|
||||
extensions: none
|
||||
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
@ -57,3 +63,31 @@ jobs:
|
||||
if-no-files-found: error
|
||||
retention-days: 90
|
||||
compression-level: 9
|
||||
|
||||
- name: Pre-render PHP File
|
||||
run: |
|
||||
cd htdocs
|
||||
php ./index.php > ./index.html
|
||||
|
||||
- name: Upload `index.html` build artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
if: ${{ github.actor == 'aziascreations' }}
|
||||
with:
|
||||
name: index.html
|
||||
path: "./htdocs/index.html"
|
||||
if-no-files-found: error
|
||||
retention-days: 90
|
||||
compression-level: 9
|
||||
|
||||
- name: Remove trash
|
||||
run: |
|
||||
cd htdocs
|
||||
rm -rf parts/
|
||||
rm *.php
|
||||
|
||||
- name: Deploy demo page to gh-pages
|
||||
uses: peaceiris/actions-gh-pages@v4
|
||||
#if: ${{ github.ref == 'refs/heads/master' }}
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
publish_dir: ./htdocs
|
45
.github/workflows/php-render.yml
vendored
45
.github/workflows/php-render.yml
vendored
@ -1,45 +0,0 @@
|
||||
name: Render PHP Demo Page
|
||||
|
||||
on:
|
||||
workflow_run:
|
||||
workflows: ["Compile SASS"]
|
||||
types:
|
||||
- completed
|
||||
|
||||
jobs:
|
||||
php_render:
|
||||
if: ${{ github.event.workflow_run.conclusion == 'success' }}
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Download artifact
|
||||
uses: actions/download-artifact@v3
|
||||
if: ${{ github.actor == 'aziascreations' }}
|
||||
with:
|
||||
path: ./htdocs/css
|
||||
|
||||
- name: Display structure of downloaded files
|
||||
run: |
|
||||
cd ./htdocs/css
|
||||
ls -R
|
||||
|
||||
- name: Setup PHP
|
||||
uses: shivammathur/setup-php@v2
|
||||
with:
|
||||
php-version: '8.4'
|
||||
extensions: none
|
||||
|
||||
- name: Pre-render PHP File
|
||||
run: |
|
||||
cd htdocs
|
||||
php ./index.php > ./index.html
|
||||
|
||||
- name: Upload `index.html` build artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
if: ${{ github.actor == 'aziascreations' }}
|
||||
with:
|
||||
name: index.html
|
||||
path: "./htdocs/index.html"
|
||||
if-no-files-found: error
|
||||
retention-days: 90
|
||||
compression-level: 9
|
Loading…
Reference in New Issue
Block a user