File tree 1 file changed +8
-4
lines changed
1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change 14
14
runs-on : ubuntu-latest
15
15
strategy :
16
16
matrix :
17
- python-version : ["3.8", "3.9", "3. 10"]
17
+ python-version : ["3.10"]
18
18
steps :
19
19
- uses : actions/checkout@v3
20
20
- name : Set up Python ${{ matrix.python-version }}
@@ -30,10 +30,14 @@ jobs:
30
30
black $(git ls-files '*.py')
31
31
- name : Commit changes
32
32
run : |
33
- git config --local user.email "action@github.com"
34
- git config --local user.name "GitHub Action"
33
+ git config --local user.email "${{ github.actor }}@users.noreply.github.com"
34
+ git config --local user.name "${{ github.actor }}"
35
+ git stash -u
36
+ black $(git ls-files '*.py')
37
+ git stash pop
35
38
git add .
36
- git diff-index --quiet HEAD || git commit -m "Format Python code with Black"
39
+ message="$(git log -1 --pretty=%B) Format Python code with Black"
40
+ git diff-index --quiet HEAD || git commit -m "$message"
37
41
- name : Push changes
38
42
run : |
39
43
git push origin master
You can’t perform that action at this time.
0 commit comments