mirror of
https://github.com/valitydev/repo-file-sync-action.git
synced 2024-11-06 09:55:21 +00:00
1.6 KiB
1.6 KiB
action-github-file-sync
🚧 UNDER DEVELOPMENT 🚧
Usage
Use the sync.yml
file to specify which files should be synced to which repos.
The top-level key should be used to specify the target repository in the format username
/repository-name
@branch
, after that you can list all the files you want to sync to that individual repository:
user/repo:
- path/to/file.txt
user/repo2:
- path/to/file2.txt
There are multiple ways to specify which files to sync to each individual repository.
List individual files
user/repo:
- .github/workflows/build.yml
- LICENSE
- .gitignore
Different destination path/filename
user/repo:
- source: workflows/build.yml
dest: .github/workflows/build.yml
- source: LICENSE.md
dest: LICENSE
Sync entire directories (coming soon)
user/repo:
- source: workflows/build.yml
dest: .github/workflows/build.yml
- source: LICENSE.md
dest: LICENSE
Match files with regex pattern (coming soon)
user/repo:
- pattern: |
^LICENSE$
^.github/workflows/sync-.*
Don't replace existing file
user/repo:
- source: .github/workflows/lint.yml
replace: false
Don't delete non-existing file (coming soon)
user/repo:
- source: .github/workflows/lint.yml
delete: false
Sync the same files to multiple repositories
group:
repos: |
user/repo
user/repo
files:
- source: workflows/build.yml
dest: .github/workflows/build.yml
- source: LICENSE.md
dest: LICENSE