Skip to content

Commit 12c249d

Browse files
authored
Update main.yml
1 parent 35832b1 commit 12c249d

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

.github/workflows/main.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ jobs:
1717

1818
- name: Set up Git
1919
run: |
20-
git config --global user.name 'naderzare'
21-
git config --global user.email 'nader.zare88@gmail.com'
20+
git config --global user.name 'GitHub Actions Bot'
21+
git config --global user.email 'actions@github.com'
2222
2323
- name: Check if README was updated
2424
run: |
@@ -32,34 +32,34 @@ jobs:
3232
id: random
3333
run: echo "::set-output name=random_number::$(shuf -i 1000-9999 -n 1)"
3434

35-
- name: Clone the second repository
35+
- name: Clone the second repository (CLSFramework.github.io)
3636
run: |
37-
git clone https://github.com/CLSFramework/CLSFramework.github.io.git
38-
cd CLSFramework.github.io
37+
git clone https://github.com/CLSFramework/CLSFramework.github.io.git cls-repo
38+
cd cls-repo
3939
40-
# Copy updated README to target directory
40+
# Copy updated README to the target directory
4141
cp ../README.md docs/2-sampleserver/0-sample-python-base-code-gRPC/index.md
4242
43-
# Create a new branch with random number appended
43+
# Create a new branch with a random number appended
4444
git checkout -b update-readme-grpc-${{ steps.random.outputs.random_number }}
4545
46-
- name: Set up authentication using PAT
46+
- name: Set up authentication using PAT for CLSFramework.github.io
4747
run: |
48-
cd CLSFramework.github.io
48+
cd cls-repo
4949
git remote set-url origin https://x-access-token:${{ secrets.GH_TOKEN }}@github.com/CLSFramework/CLSFramework.github.io.git
5050
51-
- name: Commit and Push Changes
51+
- name: Commit and Push Changes to CLSFramework.github.io
5252
run: |
53-
cd CLSFramework.github.io
53+
cd cls-repo
5454
git add docs/2-sampleserver/0-sample-python-base-code-gRPC/index.md
5555
git commit -m "Update sample server documentation from README"
5656
git push origin update-readme-grpc-${{ steps.random.outputs.random_number }}
5757
58-
- name: Create Pull Request in `CLSFramework.github.io`
58+
- name: Create Pull Request in CLSFramework.github.io
5959
uses: peter-evans/create-pull-request@v5
6060
with:
6161
token: ${{ secrets.GH_TOKEN }}
62-
repository: CLSFramework/CLSFramework.github.io # Explicitly set the target repo
62+
repository: CLSFramework/CLSFramework.github.io # Target the correct repository
6363
branch: update-readme-grpc-${{ steps.random.outputs.random_number }}
6464
commit-message: "Update sample server documentation from README"
6565
title: "Update sample server documentation"

0 commit comments

Comments
 (0)