File tree Expand file tree Collapse file tree 1 file changed +18
-1
lines changed
Expand file tree Collapse file tree 1 file changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -298,7 +298,24 @@ async function run() {
298298
299299 core . exportVariable ( EnvVar . INIT_ACTION_HAS_RUN , "true" ) ;
300300
301- const configFile = getOptionalInput ( "config-file" ) ;
301+ let configFile = getOptionalInput ( "config-file" ) ;
302+ if ( configFile === undefined ) {
303+ const defaultLocation = path . join (
304+ getRequiredEnvParam ( "GITHUB_WORKSPACE" ) ,
305+ ".github" ,
306+ "codeql" ,
307+ "codeql.yml" ,
308+ ) ;
309+
310+ if ( fs . existsSync ( defaultLocation ) ) {
311+ configFile = defaultLocation ;
312+ logger . info (
313+ `Using default config file location: ${ path . resolve ( configFile ) } ` ,
314+ ) ;
315+ } else {
316+ logger . info ( "No config file found." ) ;
317+ }
318+ }
302319
303320 try {
304321 const statusReportBase = await createStatusReportBase (
You can’t perform that action at this time.
0 commit comments