File tree 3 files changed +13
-2
lines changed
3 files changed +13
-2
lines changed Original file line number Diff line number Diff line change 15
15
with :
16
16
python-version : " 3.7"
17
17
- uses : ccdc-opensource/commit-hooks@jira_bld_5704_jira_id_in_commit_message
18
+ with :
19
+ commit-message : ${{ github.event.head_commit.message }}
Original file line number Diff line number Diff line change @@ -4,8 +4,12 @@ description: Check changed files for compliance
4
4
runs :
5
5
using : " composite"
6
6
steps :
7
- - run : python3 $GITHUB_ACTION_PATH/main.py ${{ github.event.head_commit.message }}
7
+ - run : python3 $GITHUB_ACTION_PATH/main.py
8
8
shell : bash
9
+ inputs :
10
+ commit-message :
11
+ description : ' The commit message, ie. ${{ github.event.head_commit.message }}'
12
+ required : true
9
13
branding :
10
14
icon : ' check-square'
11
15
color : ' green'
Original file line number Diff line number Diff line change 6
6
7
7
'''
8
8
9
+ import os
9
10
from pathlib import Path
10
11
import sys
11
12
14
15
15
16
if __name__ == '__main__' :
16
17
17
- message = sys .argv [1 ]
18
+ for k ,v in os .environ .items ():
19
+ if k .startswith ('INPUT_' ):
20
+ print (k , v )
21
+
22
+ message = ''
18
23
print (f'Commit message: { message } ' )
19
24
20
25
print (f'Checking commit { githooks .get_sha ()} by { githooks .get_user ()} in { githooks .get_branch ()} ' )
You can’t perform that action at this time.
0 commit comments