@@ -297,7 +297,7 @@ async function maybeDownload(
297297 let elidePath : string = targetBin
298298 /* istanbul ignore next */
299299 let elideHome : string = process . env . ELIDE_HOME || options . target
300- let elidePathTarget = elideHome ;
300+ let elidePathTarget = elideHome
301301 const elideBin : string = elideHome // @TODO (sgammon): bin folder?
302302 let elideDir : string | null = null
303303
@@ -311,13 +311,13 @@ async function maybeDownload(
311311 core . debug ( `Failed to locate Elide in tool cache: ${ err } ` )
312312 }
313313 /* istanbul ignore next */
314- if ( options . cache && elideDir ) {
314+ if ( options . no_cache !== true && elideDir ) {
315315 // we have an existing cached copy of elide
316316 core . debug ( 'Caching enabled and cached Elide release found; using it' )
317317 elidePath = elideDir
318318 } else {
319319 /* istanbul ignore next */
320- if ( ! options . cache ) {
320+ if ( options . no_cache ) {
321321 core . debug (
322322 'Cache disabled; forcing a fetch of the specified Elide release'
323323 )
@@ -346,17 +346,19 @@ async function maybeDownload(
346346 version . tag_name ,
347347 options
348348 )
349- elidePathTarget = elideHome ;
350- if ( options . cache ) {
349+ elidePathTarget = elideHome
350+
351+ if ( options . no_cache !== true ) {
351352 // cache the tool
352353 const cachedPath = await toolCache . cacheDir (
353354 elideHome ,
354355 'elide' ,
355356 version . tag_name ,
356- options . arch ) ;
357+ options . arch
358+ )
357359
358- elidePathTarget = cachedPath ;
359- core . debug ( `Elide release cached at: ${ cachedPath } ` ) ;
360+ elidePathTarget = cachedPath
361+ core . debug ( `Elide release cached at: ${ cachedPath } ` )
360362 } else {
361363 core . debug ( 'Tool caching is disabled; not caching downloaded release' )
362364 }
0 commit comments