Skip to content

Added mkdir commando in case reports don't exist #21

Added mkdir commando in case reports don't exist

Added mkdir commando in case reports don't exist #21

# This is a basic workflow to help you get started with Actions
name: generate_reports
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the "main" branch
push:
branches: ["main"]
paths-ignore:
- "**/README.md"
pull_request:
branches: ["main"]
paths-ignore:
- "**/README.md"
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "validate-standaarden"
validate-standaarden:
# The type of runner that the job will run on
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
# Different Node versions. Each node version will trigger the action
node-version:
- 16.x
# - 18.x
steps:
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
# Runs a single command using the runners shell
- name: Check out repository
uses: actions/checkout@v4
- name: Install dependencies
run: |
npm install
- name: Build project
run: npm run build:clean
- name: Generate the reports
shell: bash
run: |
# make file runnable, might not be necessary
chmod +x "${GITHUB_WORKSPACE}/.github/scripts/run_generate_reports.sh"
# run script
"${GITHUB_WORKSPACE}/.github/scripts/run_generate_reports.sh"
"ls -la"
- name: Commit and push changes
uses: actions/checkout@v4
- run: |
date > generated.txt
git config user.name github-actions
git config user.email [email protected]
git status
ls
git add .
git commit -m "generated"
git push