mirror of
				https://kkgithub.com/actions/setup-python.git
				synced 2025-11-04 04:31:51 +08:00 
			
		
		
		
	Force RUNNER_TOOL_CACHE to be equal AGENT_TOOLSDIRECTORY
This commit is contained in:
		@ -25,6 +25,13 @@ async function cacheDependencies(cache: string, pythonVersion: string) {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
async function run() {
 | 
			
		||||
 | 
			
		||||
  if (process.env['AGENT_TOOLSDIRECTORY'] !== undefined) {
 | 
			
		||||
    core.debug('Python is expected to be installed into AGENT_TOOLSDIRECTORY=' + process.env['AGENT_TOOLSDIRECTORY'] )
 | 
			
		||||
    process.env['RUNNER_TOOL_CACHE'] = process.env['AGENT_TOOLSDIRECTORY']
 | 
			
		||||
  } else {
 | 
			
		||||
    core.debug('Python is expected to be installed into RUNNER_TOOL_CACHE=' + process.env['RUNNER_TOOL_CACHE'] )
 | 
			
		||||
  }
 | 
			
		||||
  try {
 | 
			
		||||
    const version = core.getInput('python-version');
 | 
			
		||||
    if (version) {
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user