Skip to content

Commit 0a52df8

Browse files
authored
Merge pull request #1334 from aFlyBird0/feat-staging-repo-sync
feat: sync repos under staging folder to individual repos
2 parents 790918f + a6090b8 commit 0a52df8

File tree

3 files changed

+79
-0
lines changed

3 files changed

+79
-0
lines changed

.github/sync-staging-repo.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
devstream-io/dtm-gitlab-share-library:
2+
- source: staging/dtm-gitlab-share-library/
3+
dest: .
4+
deleteOrphaned: true
5+
devstream-io/dtm-jenkins-share-library:
6+
- source: staging/dtm-jenkins-share-library/
7+
dest: .
8+
deleteOrphaned: true
9+
devstream-io/dtm-pipeline-templates:
10+
- source: staging/dtm-pipeline-templates/
11+
dest: .
12+
deleteOrphaned: true
13+
devstream-io/dtm-repo-scaffolding-golang:
14+
- source: staging/dtm-repo-scaffolding-golang/
15+
dest: .
16+
deleteOrphaned: true
17+
devstream-io/dtm-repo-scaffolding-golang-cli:
18+
- source: staging/dtm-repo-scaffolding-golang-cli/
19+
dest: .
20+
deleteOrphaned: true
21+
devstream-io/dtm-repo-scaffolding-golang-gin:
22+
- source: staging/dtm-repo-scaffolding-golang-gin/
23+
dest: .
24+
deleteOrphaned: true
25+
devstream-io/dtm-repo-scaffolding-java-springboot:
26+
- source: staging/dtm-repo-scaffolding-java-springboot/
27+
dest: .
28+
deleteOrphaned: true
29+
devstream-io/dtm-repo-scaffolding-python:
30+
- source: staging/dtm-repo-scaffolding-python/
31+
dest: .
32+
deleteOrphaned: true
33+
devstream-io/dtm-repo-scaffolding-python-flask:
34+
- source: staging/dtm-repo-scaffolding-python-flask/
35+
dest: .
36+
deleteOrphaned: true
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Sync Staging Files to Other Repos
2+
on:
3+
push:
4+
branches: [ main ]
5+
paths:
6+
- staging/**
7+
- .github/workflows/sync-staging-repo.yml
8+
- .github/sync-staging-repo.yml
9+
workflow_dispatch:
10+
11+
jobs:
12+
sync:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout
16+
uses: actions/checkout@v3
17+
- name: Run GitHub File Sync
18+
uses: BetaHuhn/[email protected]
19+
with:
20+
GH_PAT: ${{ secrets.GH_PAT }}
21+
CONFIG_PATH: .github/sync-staging-repo.yml
22+
ORIGINAL_MESSAGE: true
23+
SKIP_PR: true
24+
COMMIT_EACH_FILE: false

staging/README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Staging Repos
2+
3+
This directory contains the staging repositories for the Devstream project.
4+
5+
Each sub folder under `staging/` be synchronized to the repository of the same name under devstream-io.
6+
7+
## How to Create a New Staging Repo
8+
9+
Person who wants to create a new staging repo:
10+
11+
1. Create a new directory under `staging/` with the name of the repo you want to create.
12+
2. Update [`.github/sync-staging-repo.yml`](../.github/sync-staging-repo.yml).
13+
3. Pull Request to the `main` branch of repo `devstream-io/devstream`.
14+
15+
Reviewers:
16+
17+
1. Review the PR, make sure everything is correct, and do not merge it immediately.
18+
2. Create the repo under the `devstream-io` organization and **create a branch for the repo**. If you don't have the permission to create a repo, please ask for the members of the `devstream-io`.
19+
3. Merge the PR.

0 commit comments

Comments
 (0)