mirror of
				https://github.com/actions/checkout.git
				synced 2025-10-30 23:10:31 +00:00 
			
		
		
		
	.
This commit is contained in:
		| @@ -205,13 +205,13 @@ class GitAuthHelper { | |||||||
|       // For each submodule, configure includeIf entries pointing to the shared credentials file. |       // For each submodule, configure includeIf entries pointing to the shared credentials file. | ||||||
|       // Configure both host and container paths to support Docker container actions. |       // Configure both host and container paths to support Docker container actions. | ||||||
|       for (const configPath of configPaths) { |       for (const configPath of configPaths) { | ||||||
|         // The config file is at .git/modules/submodule-name/config |         // Submodule Git directory | ||||||
|         let submoduleConfigDir = path.dirname(configPath) |         let submoduleGitDir = path.dirname(configPath) // The config file is at .git/modules/submodule-name/config | ||||||
|         submoduleConfigDir = submoduleConfigDir.replace(/\\/g, '/') // Use forward slashes, even on Windows |         submoduleGitDir = submoduleGitDir.replace(/\\/g, '/') // Use forward slashes, even on Windows | ||||||
|  |  | ||||||
|         // Configure host includeIf |         // Configure host includeIf | ||||||
|         await this.git.config( |         await this.git.config( | ||||||
|           `includeIf.gitdir:${submoduleConfigDir}.path`, |           `includeIf.gitdir:${submoduleGitDir}.path`, | ||||||
|           credentialsConfigPath, |           credentialsConfigPath, | ||||||
|           false, |           false, | ||||||
|           false, |           false, | ||||||
| @@ -219,17 +219,14 @@ class GitAuthHelper { | |||||||
|         ) |         ) | ||||||
|  |  | ||||||
|         // Configure container includeIf |         // Configure container includeIf | ||||||
|         let relativeSubmoduleConfigDir = path.relative( |         let relativeSubmoduleGitDir = path.relative( | ||||||
|           githubWorkspace, |           githubWorkspace, | ||||||
|           submoduleConfigDir |           submoduleGitDir | ||||||
|         ) |         ) | ||||||
|         relativeSubmoduleConfigDir = relativeSubmoduleConfigDir.replace( |         relativeSubmoduleGitDir = relativeSubmoduleGitDir.replace(/\\/g, '/') // Use forward slashes, even on Windows | ||||||
|           /\\/g, |  | ||||||
|           '/' |  | ||||||
|         ) // Use forward slashes, even on Windows |  | ||||||
|         const containerSubmoduleGitDir = path.posix.join( |         const containerSubmoduleGitDir = path.posix.join( | ||||||
|           '/github/workspace', |           '/github/workspace', | ||||||
|           relativeSubmoduleConfigDir |           relativeSubmoduleGitDir | ||||||
|         ) |         ) | ||||||
|         await this.git.config( |         await this.git.config( | ||||||
|           `includeIf.gitdir:${containerSubmoduleGitDir}.path`, |           `includeIf.gitdir:${containerSubmoduleGitDir}.path`, | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 eric sciple
					eric sciple