-
-
Notifications
You must be signed in to change notification settings - Fork 113
48 lines (37 loc) · 1.59 KB
/
UpdateLLMCodes.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
46
47
48
name: Copy LLMCoder folder to LLMCodes repo
on:
workflow_dispatch:
jobs:
copy_folder:
runs-on: ubuntu-latest
steps:
- name: Checkout current repo
uses: actions/checkout@v2
with:
path: current-repo
- name: Commit to another repo
run: |
echo "--------SETTING NAME--------------"
git config --global user.name 'GitHub Actions Bot'
git config --global user.email 'actions@github.com'
# Clones the other repository where you want to commit the changes.
echo "--------CLONING LLMCodes REPO--"
git clone https://x-access-token:${{ secrets.GH_TOKEN }}@github.com/VedAstro/LLMCodes.git
# Change directory into the cloned repository.
cd LLMCodes
# Clear all files in the target repository
echo "--------CLEARING FILES IN LLMCodes REPO--"
git rm -rf .
git commit -m "🤖 Robot : Cleaning repo for rocket launch 🚀"
git push
# Copy the LLMCoder folder from the current repository into the cloned repository.
echo "--------COPYING LLMCoder FOLDER INTO LLMCodes--"
cp -r ../current-repo/LLMCoder/* .
# Add, commit, and push the changes to the other repository using the PAT.
echo "--------MAKING A COMMIT--"
git add .
git commit -m "🤖 Robot : Latest LLMCodes source injected from main repo with 💖"
echo "--------MAKING A PUSH FOR IT!--"
git push
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}