File tree 1 file changed +32
-0
lines changed
1 file changed +32
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Create Patch
2
+
3
+ on :
4
+ push :
5
+ branches-ignore :
6
+ - master
7
+ - development
8
+
9
+ jobs :
10
+ create-patch :
11
+ runs-on : ubuntu-latest
12
+ steps :
13
+ - uses : actions/checkout@v2
14
+ with :
15
+ fetch-depth : 0
16
+ - name : Create Patch
17
+ run : |
18
+ git rev-parse --abbrev-ref HEAD > .branch-name
19
+ git checkout development
20
+ git checkout -b patch
21
+ git merge --squash `cat .branch-name`
22
+ git config --global user.email "$AUTHOR_EMAIL"
23
+ git config --global user.name "$AUTHOR_NAME"
24
+ git commit -m "Patch for `cat .branch-name`"
25
+ git format-patch development..HEAD --stdout -k > patch.diff
26
+ env :
27
+ AUTHOR_EMAIL : ${{ github.event.head_commit.author.email }}
28
+ AUTHOR_NAME : ${{ github.event.head_commit.author.name }}
29
+ - uses : actions/upload-artifact@v2
30
+ with :
31
+ name : patch
32
+ path : patch.diff
You can’t perform that action at this time.
0 commit comments