Skip to content

Commit 37c5c4f

Browse files
doc(README): add description how to use the action (#2) (#22)
1 parent 5c8dbec commit 37c5c4f

File tree

1 file changed

+41
-1
lines changed

1 file changed

+41
-1
lines changed

README.md

+41-1
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,50 @@
1-
# template
1+
# actions-template-sync
22
<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
33
[![All Contributors](https://img.shields.io/badge/all_contributors-1-orange.svg?style=flat-square)](#contributors-)
44
<!-- ALL-CONTRIBUTORS-BADGE:END -->
55

66
![Lint](https://github.com/AndreasAugustin/actions-template-sync/workflows/Lint/badge.svg)
77

8+
It is possible to create repositories within Github with
9+
[GitHub templates](https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/creating-a-template-repository).
10+
This is a nice approach to have some boilerplate within your repository.
11+
Over the time the template repository will get some code changes.
12+
The problem is that the already created repositories won't know about those changes.
13+
This GitHub action will help you to keep track of the template changes.
14+
15+
## Features
16+
17+
* Sync template repository with the current repository
18+
19+
## Usage
20+
21+
### GitHub Actions
22+
23+
Add this configuration to your github action
24+
25+
```yaml
26+
# File: .github/workflows/template-sync.yml
27+
28+
on:
29+
schedule:
30+
- cron: "*/15 * * * *"
31+
jobs:
32+
repo-sync:
33+
runs-on: ubuntu-latest
34+
35+
steps:
36+
# To use this repository's private action, you must check out the repository
37+
- name: Checkout
38+
uses: actions/checkout@v2
39+
- name: actions-template-sync
40+
uses: actions/actions-template-sync
41+
with:
42+
github_token: ${{ secrets.GITHUB_TOKEN }}
43+
source_repo_path: <the_path_to_the_repo>
44+
```
45+
46+
You will receive a pull request within your repository if there are some changes available.
47+
848
## DEV
949
1050
The development environment targets are located in the [Makefile](Makefile)

0 commit comments

Comments
 (0)