-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #309 from SaintAngeLs/dev
#305 add syncronisation with gitlab
- Loading branch information
Showing
296 changed files
with
10,638 additions
and
2,602 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
name: Sync to GitLab Repositories | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' | ||
pull_request: | ||
types: [closed] | ||
branches: | ||
- '*' | ||
|
||
jobs: | ||
Sync: | ||
runs-on: ubuntu-latest | ||
env: | ||
GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }} | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GITHUB_REPO: ${{ github.repository }} | ||
GITLAB_REPO_1: 'SaintAngeLs/distributed_minispace' | ||
GITLAB_REPO_2: 'distributed-asp-net-core-blazor-social-app/distributed_minispace' | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
with: | ||
submodules: true | ||
fetch-depth: 0 # Fetch all branches and tags | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.x' | ||
|
||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install requests | ||
- name: Configuring git | ||
run: | | ||
git config --global user.email "voznesenskijandrej5@gmail.com" | ||
git config --global user.name "Andrii Voznesenskyi" | ||
- name: Adding GitLab remote repository 1 | ||
run: | | ||
GITLAB_REPO="https://oauth2:${{ secrets.GITLAB_TOKEN }}@gitlab.com/SaintAngeLs/distributed_minispace.git" | ||
git remote add gitlab1 $GITLAB_REPO || git remote set-url gitlab1 $GITLAB_REPO | ||
- name: Adding GitLab remote repository 2 | ||
run: | | ||
GITLAB_REPO="https://oauth2:${{ secrets.GITLAB_TOKEN }}@gitlab.com/distributed-asp-net-core-blazor-social-app/distributed_minispace.git" | ||
git remote add gitlab2 $GITLAB_REPO || git remote set-url gitlab2 $GITLAB_REPO | ||
- name: Push all branches to both GitLab repositories | ||
run: | | ||
git push gitlab1 --all --force | ||
git push gitlab2 --all --force | ||
- name: Push all tags to both GitLab repositories | ||
run: | | ||
git push gitlab1 --tags --force | ||
git push gitlab2 --tags --force | ||
- name: Sync Pull Requests and Issues to GitLab | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }} | ||
GITHUB_REPO: ${{ github.repository }} | ||
GITLAB_REPO_1: 'SaintAngeLs/distributed_minispace' | ||
GITLAB_REPO_2: 'distributed-asp-net-core-blazor-social-app/distributed_minispace' | ||
run: python .github/workflows/sync_prs_issues.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
name: Sync PRs and Issues to GitLab | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' | ||
pull_request: | ||
types: [closed] | ||
branches: | ||
- '*' | ||
schedule: | ||
- cron: '0 * * * *' # Runs every hour | ||
workflow_dispatch: | ||
|
||
jobs: | ||
Sync: | ||
runs-on: ubuntu-latest | ||
env: | ||
GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }} | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GITHUB_REPO: ${{ github.repository }} | ||
GITLAB_REPO_1: 'SaintAngeLs/distributed_minispace' | ||
GITLAB_REPO_2: 'distributed-asp-net-core-blazor-social-app/distributed_minispace' | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
with: | ||
submodules: true | ||
fetch-depth: 0 # Fetch all branches and tags | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.x' | ||
|
||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install requests | ||
- name: Configuring git | ||
run: | | ||
git config --global user.email "voznesenskijandrej5@gmail.com" | ||
git config --global user.name "Andrii Voznesenskyi" | ||
- name: Adding GitLab remote repository 1 | ||
run: | | ||
GITLAB_REPO="https://oauth2:${{ secrets.GITLAB_TOKEN }}@gitlab.com/SaintAngeLs/distributed_minispace.git" | ||
git remote add gitlab1 $GITLAB_REPO || git remote set-url gitlab1 $GITLAB_REPO | ||
- name: Adding GitLab remote repository 2 | ||
run: | | ||
GITLAB_REPO="https://oauth2:${{ secrets.GITLAB_TOKEN }}@gitlab.com/distributed-asp-net-core-blazor-social-app/distributed_minispace.git" | ||
git remote add gitlab2 $GITLAB_REPO || git remote set-url gitlab2 $GITLAB_REPO | ||
- name: Push all branches to both GitLab repositories | ||
run: | | ||
git push gitlab1 --all --force | ||
git push gitlab2 --all --force | ||
- name: Push all tags to both GitLab repositories | ||
run: | | ||
git push gitlab1 --tags --force | ||
git push gitlab2 --tags --force | ||
- name: Sync Pull Requests and Issues to GitLab | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }} | ||
GITHUB_REPO: ${{ github.repository }} | ||
GITLAB_REPO_1: 'SaintAngeLs/distributed_minispace' | ||
GITLAB_REPO_2: 'distributed-asp-net-core-blazor-social-app/distributed_minispace' | ||
run: python .github/workflows/sync_prs_issues.py |
Oops, something went wrong.