Skip to content

Commit bba2bde

Browse files
authored
Update sample-file-trigger.yml
1 parent ad47221 commit bba2bde

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

.github/workflows/sample-file-trigger.yml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,21 +28,17 @@ jobs:
2828
echo "file_path=$ADDED_FILE" >> $GITHUB_ENV
2929
3030
- name: Show file name and content
31-
id: show_file
3231
run: |
3332
echo "Reading content of: ${{ env.file_path }}"
34-
echo "File path: ${{ env.file_path }}"
3533
cat "${{ env.file_path }}"
36-
FILE_CONTENT=$(cat "${{ env.file_path }}")
37-
echo "file_content<<EOF" >> $GITHUB_ENV
38-
echo "$FILE_CONTENT" >> $GITHUB_ENV
39-
echo "EOF" >> $GITHUB_ENV
34+
cp "${{ env.file_path }}" input_file.txt
4035
4136
- name: Extract Commands and Properties (OpenAI Part 1)
4237
run: |
4338
echo "Calling OpenAI to extract commands and properties..."
39+
4440
SYSTEM_PROMPT=$(cat .github/prompts/extract_prompt.txt)
45-
USER_CONTENT="${{ env.file_content }}"
41+
USER_CONTENT=$(cat input_file.txt)
4642
4743
PAYLOAD=$(jq -n --arg sys "$SYSTEM_PROMPT" --arg usr "$USER_CONTENT" '{
4844
model: "gpt-4o",
@@ -64,6 +60,7 @@ jobs:
6460
- name: Generate Markdown Documentation (OpenAI Part 2)
6561
run: |
6662
echo "Generating final Markdown documentation..."
63+
6764
SYSTEM_PROMPT=$(cat .github/prompts/generate_prompt.txt)
6865
EXTRACTED_CONTENT=$(cat extracted_info.md)
6966

0 commit comments

Comments
 (0)