Skip to content
40 changes: 38 additions & 2 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,18 @@ on:


permissions:
contents: read # This is required for actions/checkout
contents: write # This is required for actions/checkout
pull-requests: write
id-token: write # This is required requesting the JWT

jobs:
auto_assign:
runs-on: ubuntu-latest
if: github.event_name == 'pull_request' && github.event.action != 'closed'
#if: github.event_name == 'pull_request' && github.event.action != 'closed'
if: github.event.review.state == 'commented'
steps:
- name: Debug Event Payload
run: echo "${{ toJson(github.event) }}"
- name: Checkout code
uses: actions/checkout@v4
- name: configure aws credentials
Expand Down Expand Up @@ -109,6 +112,39 @@ jobs:
-d "{\"team_reviewers\":[\"ai4sdlc-approval\"]}" \
https://api.github.com/repos/${{ github.repository }}/pulls/$PR_NUMBER/requested_reviewers -v


###
# Build stage - converting md file to html using MkDocs
convert_md_to_html_gh :
runs-on: ubuntu-latest
if: github.ref != 'refs/heads/main' # Run for non-main branches
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.9

- name: Install MkDocs and dependencies
run: |
pip install mkdocs mkdocs-material

- name: Build project with MkDocs
run: |
echo "Building your project..."
mkdocs build
echo "pwd in build project with MKDocs"
- name: Add .nojekyll
run: touch site/.nojekyll

- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./site
###

# Build stage - converting md file to html using MkDocs
convert_md_to_html:
Expand Down
Loading