diff --git a/.github/workflows/README.md b/.github/workflows/README.md new file mode 100644 index 0000000..4570a06 --- /dev/null +++ b/.github/workflows/README.md @@ -0,0 +1,40 @@ +# Auto Review Documentation Workflow + +This workflow automatically reviews documentation changes and can be triggered in two ways: + +## Triggers + +### 1. Automatic Trigger +- **Push to main branch**: The workflow automatically runs when changes are pushed to the `main` branch + +### 2. Manual Trigger (workflow_dispatch) +- **Manual execution**: You can manually trigger this workflow from the GitHub Actions UI +- **Any branch**: Can be run on any branch or commit, not just `main` +- **On-demand review**: Useful for reviewing documentation changes before merging + +## How to Run Manually + +1. Go to the **Actions** tab in your GitHub repository +2. Select **Auto Review Documentation** from the workflow list +3. Click **Run workflow** +4. Choose the branch you want to run the workflow on +5. Click **Run workflow** to start the manual execution + +## Benefits of workflow_dispatch + +- **Flexibility**: Run documentation reviews on feature branches before merging +- **Testing**: Test workflow changes without needing to push to main +- **On-demand reviews**: Review documentation at any time, not just on push events +- **Quality assurance**: Ensure documentation quality across all branches + +## Workflow Configuration + +```yaml +on: + push: + branches: + - main + workflow_dispatch: +``` + +The `workflow_dispatch` trigger enables manual runs from the Actions tab, allowing you to select any branch or commit for review. \ No newline at end of file diff --git a/.github/workflows/auto_review_documentation.yml b/.github/workflows/auto_review_documentation.yml new file mode 100644 index 0000000..67bdbc8 --- /dev/null +++ b/.github/workflows/auto_review_documentation.yml @@ -0,0 +1,39 @@ +name: Auto Review Documentation + +on: + push: + branches: + - main + workflow_dispatch: + +jobs: + review-documentation: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Setup Python + uses: actions/setup-python@v4 + with: + python-version: '3.x' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + if [ -f requirements.txt ]; then pip install -r requirements.txt; fi + + - name: Review documentation + run: | + echo "Reviewing documentation changes..." + echo "Found markdown files:" + find . -name "*.md" -type f + echo "" + echo "Checking documentation structure..." + echo "Documentation files in docs/:" + ls -la docs/ || echo "No docs directory found" + echo "" + echo "Checking for broken links and basic formatting..." + # Add your documentation review logic here + # This could include linting, spell checking, or other validation \ No newline at end of file