@@ -7,7 +7,7 @@ import {setFailure} from './helpers';
7
7
8
8
const context = github . context ;
9
9
10
- const isTrue = ( variable ) => {
10
+ const isTrue = ( variable : string ) : boolean => {
11
11
const lowercase = variable . toLowerCase ( ) ;
12
12
return (
13
13
lowercase === '1' ||
@@ -18,7 +18,7 @@ const isTrue = (variable) => {
18
18
) ;
19
19
} ;
20
20
21
- const getGitService = ( ) => {
21
+ const getGitService = ( ) : string => {
22
22
const overrideGitService = core . getInput ( 'git_service' ) ;
23
23
const serverUrl = process . env . GITHUB_SERVER_URL ;
24
24
if ( overrideGitService ) {
@@ -29,7 +29,7 @@ const getGitService = () => {
29
29
return 'github' ;
30
30
} ;
31
31
32
- const getToken = async ( ) => {
32
+ const getToken = async ( ) : Promise < string > => {
33
33
let token = core . getInput ( 'token' ) ;
34
34
let url = core . getInput ( 'url' ) ;
35
35
const useOIDC = isTrue ( core . getInput ( 'use_oidc' ) ) ;
@@ -51,7 +51,11 @@ const getToken = async () => {
51
51
return token ;
52
52
} ;
53
53
54
- const buildCommitExec = async ( ) => {
54
+ const buildCommitExec = async ( ) : Promise < {
55
+ commitExecArgs : any [ ] ;
56
+ commitOptions : any ;
57
+ commitCommand : string ;
58
+ } > => {
55
59
const commitParent = core . getInput ( 'commit_parent' ) ;
56
60
const gitService = getGitService ( ) ;
57
61
const overrideBranch = core . getInput ( 'override_branch' ) ;
@@ -116,7 +120,10 @@ const buildCommitExec = async () => {
116
120
return { commitExecArgs, commitOptions, commitCommand} ;
117
121
} ;
118
122
119
- const buildGeneralExec = ( ) => {
123
+ const buildGeneralExec = ( ) : {
124
+ args : any [ ] ;
125
+ verbose : boolean ;
126
+ } => {
120
127
const codecovYmlPath = core . getInput ( 'codecov_yml_path' ) ;
121
128
const url = core . getInput ( 'url' ) ;
122
129
const verbose = isTrue ( core . getInput ( 'verbose' ) ) ;
@@ -134,7 +141,11 @@ const buildGeneralExec = () => {
134
141
return { args, verbose} ;
135
142
} ;
136
143
137
- const buildReportExec = async ( ) => {
144
+ const buildReportExec = async ( ) : Promise < {
145
+ reportExecArgs : any [ ] ;
146
+ reportOptions : any ;
147
+ reportCommand : string ;
148
+ } > => {
138
149
const gitService = getGitService ( ) ;
139
150
const overrideCommit = core . getInput ( 'override_commit' ) ;
140
151
const overridePr = core . getInput ( 'override_pr' ) ;
@@ -191,7 +202,15 @@ const buildReportExec = async () => {
191
202
return { reportExecArgs, reportOptions, reportCommand} ;
192
203
} ;
193
204
194
- const buildUploadExec = async ( ) => {
205
+ const buildUploadExec = async ( ) : Promise < {
206
+ uploadExecArgs : any [ ] ;
207
+ uploadOptions : any ;
208
+ disableSafeDirectory : boolean ;
209
+ failCi : boolean ;
210
+ os : string ;
211
+ uploaderVersion : string ;
212
+ uploadCommand : string ;
213
+ } > => {
195
214
const disableFileFixes = isTrue ( core . getInput ( 'disable_file_fixes' ) ) ;
196
215
const disableSafeDirectory = isTrue ( core . getInput ( 'disable_safe_directory' ) ) ;
197
216
const disableSearch = isTrue ( core . getInput ( 'disable_search' ) ) ;
0 commit comments