-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaction.yml
45 lines (40 loc) · 1.12 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
---
name: Generate suggestion from docs bot
description: >
TODO
runs:
using: composite
steps:
- name: Checkout action repository
uses: actions/checkout@v4
with:
repository: espressif/docs-bot-action
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.13'
cache: pip
- name: Install Python dependencies
shell: bash
run: |
python -m venv venv
source venv/bin/activate
pip install --upgrade pip
pip install -r requirements.txt
- name: Run bot_action.py
shell: bash
id: bot-action
run: |
source venv/bin/activate
echo "BOT_MSG=$(python bot_action/bot_action.py ${{ env.DOCS_BOT_IN_MSG }})" >> "$GITHUB_OUTPUT"
- name: Comment
shell: bash
run: gh issue comment "$NUMBER" --body "$BODY"
env:
GH_TOKEN: ${{ env.GITHUB_TOKEN }}
GH_REPO: ${{ env.GITHUB_REPOSITORY }}
NUMBER: ${{ env.GITHUB_ISSUE_NUMBER }}
BODY: >
${{ env.DOCS_BOT_PREFIX_OUT_MSG }}
---
${{ steps.bot-action.outputs.BOT_MSG }}