File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,16 @@ Example workflow to sync commits and tags.
37
37
38
38
``` yaml
39
39
on :
40
+ on :
40
41
push :
42
+ # Only trigger for specific branches or changes in specific paths.
43
+ branches :
44
+ - ' *'
45
+ paths :
46
+ - src/**
47
+ # Tag push events should be ignored, they will be handled with the create event below.
48
+ tags-ignore :
49
+ - ' *'
41
50
create :
42
51
tags :
43
52
- ' *'
51
60
name : Sync commits
52
61
steps :
53
62
- uses : actions/checkout@v2
63
+ with :
64
+ persist-credentials : false
65
+ fetch-depth : 0
54
66
55
67
# Add a personal access token to the repository secrets. This will allow the splitter action to push the new commits
56
68
- uses : frankdejonge/use-github-token@1.0.1
68
80
69
81
# Retrieve the branch name of the branch that triggered the build.
70
82
- name : Extract branch name
83
+ id : vars
71
84
run : echo ::set-output name=branch_name::${GITHUB_REF#refs/*/}
72
85
73
86
# Sync commits and tags for the configured subtree splits
You can’t perform that action at this time.
0 commit comments