name: dev_catalog_validation

on:
  push:
  workflow_dispatch:

jobs:
  ix-dev-validate:
    runs-on: ubuntu-latest

    container:
      image: ixsystems/catalog_validation:latest

    steps:
      - uses: actions/checkout@v3
        with:
          fetch-depth: 0
      - name: Adding git directory to safe path
        run: git config --global --add safe.directory "$(pwd)"
      - name: Fetch base branch history
        run: git fetch -u origin master:master
      - name: validate dev catalog
        run: /bin/bash -c "/usr/local/bin/dev_charts_validate validate --path $(pwd)"
