You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README_en.md
+9-18Lines changed: 9 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,38 +6,28 @@ Action for mirroring repos between Hubs (like GitHub, Gitee, and GitLab).
6
6
7
7
## Tutorial
8
8
9
-
### Mirror GitHub to Gitee
10
9
```yaml
11
10
steps:
12
11
- name: Mirror the Github organization repos to Gitee.
13
12
uses: Yikun/hub-mirror-action@master
14
13
with:
14
+
# Support gitee, github and gitlab
15
15
src: github/kunpengcompute
16
+
# Support gitee, github and gitlab
16
17
dst: gitee/kunpengcompute
17
18
dst_key: ${{ secrets.GITEE_PRIVATE_KEY }}
18
19
dst_token: ${{ secrets.GITEE_TOKEN }}
20
+
# Support github/gitee user, org and gitlab group
19
21
account_type: org
22
+
# Supporte set account type speparately
20
23
# src_account_type: org
21
24
# dst_account_type: org
22
25
```
23
-
### Mirror GitHub to Gitlab
24
-
```yaml
25
-
steps:
26
-
- name: Mirror the GitHub organization repos to GitLab.
27
-
uses: Yikun/hub-mirror-action@master
28
-
with:
29
-
src: github/kunpengcompute
30
-
dst: gitlab/kunpengcompute
31
-
dst_key: ${{ secrets.GITLAB_PRIVATE_KEY }}
32
-
dst_token: ${{ secrets.GITLAB_TOKEN }}
33
-
account_type: group
34
-
src_account_type: org
35
-
dst_account_type: group
36
-
```
37
-
38
26
39
27
Here is a workflow to mirror the kunpengcompute org repos from Github to Gitee, see more complete workflows in [here](https://github.com/Yikun/hub-mirror-action/tree/master/.github/workflows).
40
28
29
+
Please refer to [scenarios](https://github.com/Yikun/hub-mirror-action/blob/master/README_en.md#scenarios) for more examples.
30
+
41
31
## Who are using?
42
32
More than [100+](https://github.com/search?p=2&q=hub-mirror-action+%22account_type%22+%22org%22&type=Code) organizations,[4000+](https://github.com/search?l=YAML&q=%22hub-mirror-action%22&type=Code) users are using, [50+](https://github.com/search?l=Markdown&q=%22hub-mirror-action%22&type=code) related blogs from users:
43
33
@@ -215,8 +205,9 @@ Note: please configure the public key of `dst_key` to the source (github in here
215
205
You can use below steps to add secrets, you can also see more in [Secrets](https://help.github.com/en/actions/configuring-and-managing-workflows/creating-and-storing-encrypted-secrets).
216
206
217
207
1. **Get Token and Key**:
218
-
* For Gitee: Get SSH key from [here](https://gitee.com/profile/sshkeys) and token from [here](https://gitee.com/profile/personal_access_tokens)
219
-
* For GitLab: Get SSH key from [here](https://gitlab.com/-/user_settings/ssh_keys) and token from [here](https://gitlab.com/-/user_settings/personal_access_tokens)
208
+
- Github: Configure and save your [ssh key](https://github.com/settings/keys)和[token](https://github.com/settings/tokens)
209
+
- Gitee: Configure and save your [ssh key](https://gitee.com/profile/sshkeys)和[token](https://gitee.com/profile/personal_access_tokens)
210
+
- Gtilab: Configure and save your [ssh key](https://gitlab.com/-/user/settings/keys)和[token](https://gitlab.com/-/user_settings/personal_access_tokens)
220
211
2. **Add Secrets**,add settings-secrets in repo,like `GITEE_PRIVATE_KEY`、`GITEE_TOKEN` or `GITLAB_PRIVATE_KEY`、`GITLAB_TOKEN`
221
212
3. **Add workflow**,add the workflow file into .github/workflows.
0 commit comments