Update gulp-build.yml #22
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Test | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out the repository | |
uses: actions/checkout@v3 | |
- name: Set up Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '20' | |
- name: Ensure write permissions | |
run: chmod -R 777 ./dist | |
- name: Clean up dist folder | |
run: rm -rf ./dist && mkdir -p ./dist | |
- name: Install dependencies | |
run: npm install | |
- name: Run Gulp Build | |
run: npm run build | |
- name: Upload dist directory as artifact | |
if: always() | |
uses: actions/upload-artifact@v3 | |
with: | |
name: dist-folder | |
path: ./dist | |
- name: Download dist-folder artifact to dist | |
uses: actions/download-artifact@v3 | |
with: | |
name: dist-folder | |
path: ./dist |