Skip to content

Commit

Permalink
Update createGuide.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
hadar-co authored Nov 13, 2024
1 parent 0e1293b commit b6e34fe
Showing 1 changed file with 16 additions and 16 deletions.
32 changes: 16 additions & 16 deletions .github/workflows/createGuide.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,27 +94,27 @@ jobs:
echo "$ASSISTANT_MESSAGE" > guide.md
shell: bash

- name: Configure Git
run: |
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
# - name: Configure Git
# run: |
# git config --global user.name 'github-actions[bot]'
# git config --global user.email 'github-actions[bot]@users.noreply.github.com'

- name: Create and Push Branch with Guide
id: create_branch
run: |
ls -al
export BRANCH_NAME="new-guide-branch-${{ github.run_id }}"
echo "NEW_BRANCH=$BRANCH_NAME" >> $GITHUB_ENV
git checkout -b "$BRANCH_NAME"
git add guide.md
git commit -m "Add generated guide: ${{ github.event.inputs.title }}"
git push origin "$BRANCH_NAME"
shell: bash
# - name: Create and Push Branch with Guide
# id: create_branch
# run: |
# ls -al
# export BRANCH_NAME="new-guide-branch-${{ github.run_id }}"
# echo "NEW_BRANCH=$BRANCH_NAME" >> $GITHUB_ENV
# git checkout -b "$BRANCH_NAME"
# git add guide.md
# git commit -m "Add generated guide: ${{ github.event.inputs.title }}"
# git push origin "$BRANCH_NAME"
# shell: bash

- name: Create Pull Request
uses: peter-evans/create-pull-request@v5
with:
branch: ${{ env.NEW_BRANCH }}
branch: "new-guide-branch-${{ github.run_id }}"
title: "Add Generated Guide: ${{ github.event.inputs.title }}"
body: "This PR adds a new guide generated based on the provided title and description."
base: main
Expand Down

0 comments on commit b6e34fe

Please sign in to comment.