test this

This commit is contained in:
shenjack 2023-12-16 16:31:23 +08:00
parent b502695b25
commit 2d42f39610
Signed by: shenjack
GPG Key ID: 7B1134A979775551

View File

@ -15,19 +15,20 @@ jobs:
uses: actions/checkout@v4
- name: clone remote
shell: pwsh
shell: bash
run: |
git config --global user.email 3695888@qq.com
git config --global user.name shenjack-action
git remote add gitea http://shenjack.top:5100/ARS/ars-tools.git
git fetch gitea
$branches = git branch -r | Select-String -Pattern 'gitea'
foreach ($branch in $branches) {
$branchName = $branch -replace 'gitea/', ''
$branchName = $branchName.Trim()
if (!(git branch | Select-String -Pattern $branchName)) {
git branch --track $branchName $branch.Trim()
}
}
for branch in $(git branch -r | grep 'gitea'); do
branchName=${branch#*/}
if ! git branch | grep -q $branchName; then
git branch --track $branchName $branch
fi
done
- name: push to github
run: |
git pull --all
git push origin --all --force