Skip to content

Commit

Permalink
Update create_docusaurus_page.yml (#20)
Browse files Browse the repository at this point in the history
  • Loading branch information
thefourcraft authored Sep 12, 2023
1 parent 23eeb8d commit 9e03d3e
Showing 1 changed file with 20 additions and 5 deletions.
25 changes: 20 additions & 5 deletions .github/workflows/create_docusaurus_page.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
ref: Production
token: ${{ secrets.GITHUB_TOKEN }}

- name: Create Branch
- name: Create and Checkout Branch
run: |
ISSUE_NUMBER=${{ github.event.issue.number }}
BRANCH_NAME="new-page-${ISSUE_NUMBER}"
Expand All @@ -26,8 +26,7 @@ jobs:
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
- name: Create Docusaurus File
- name: Create Docusaurus Markdown File
run: |
ISSUE_NUMBER=${{ github.event.issue.number }}
TITLE=${{ github.event.issue.body.title }}
Expand All @@ -43,9 +42,25 @@ jobs:
echo "---" >> $FILENAME
echo "$CONTENT" >> $FILENAME
git add $FILENAME
- name: Add, Commit and Push Changes
run: |
git add .
git commit -m "Create new Docusaurus page from issue $ISSUE_NUMBER"
git push origin $BRANCH_NAME
git push -u origin $BRANCH_NAME
# - name: Build Docusaurus Website
# run: |
# cd website # Navigate to your Docusaurus website directory
# npm install
# npm run build

# - name: Post Message to Original Issue
# run: |
# ISSUE_NUMBER=${{ github.event.issue.number }}
# echo "The page creation process has completed. A new branch named 'new-page-${ISSUE_NUMBER}' has been created. All tests have passed successfully." > comment.txt
# gh issue comment $ISSUE_NUMBER --body-file="comment.txt"
# env:
# GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Create Pull Request
uses: peter-evans/create-pull-request@v5
Expand Down

0 comments on commit 9e03d3e

Please sign in to comment.