mirror of
				https://gitea.com/actions/setup-go.git
				synced 2025-10-31 07:47:10 +00:00 
			
		
		
		
	Merge pull request #221 from vsafonkin/v-vsafonkin/fix-gopath-condition
Fix condition for GOPATH output
This commit is contained in:
		
							
								
								
									
										2
									
								
								dist/index.js
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								dist/index.js
									
									
									
									
										vendored
									
									
								
							| @@ -2122,7 +2122,7 @@ function addBinToPath() { | |||||||
|             return added; |             return added; | ||||||
|         } |         } | ||||||
|         let buf = child_process_1.default.execSync('go env GOPATH'); |         let buf = child_process_1.default.execSync('go env GOPATH'); | ||||||
|         if (buf) { |         if (buf.length > 1) { | ||||||
|             let gp = buf.toString().trim(); |             let gp = buf.toString().trim(); | ||||||
|             core.debug(`go env GOPATH :${gp}:`); |             core.debug(`go env GOPATH :${gp}:`); | ||||||
|             if (!fs_1.default.existsSync(gp)) { |             if (!fs_1.default.existsSync(gp)) { | ||||||
|   | |||||||
| @@ -69,7 +69,7 @@ export async function addBinToPath(): Promise<boolean> { | |||||||
|   } |   } | ||||||
|  |  | ||||||
|   let buf = cp.execSync('go env GOPATH'); |   let buf = cp.execSync('go env GOPATH'); | ||||||
|   if (buf) { |   if (buf.length > 1) { | ||||||
|     let gp = buf.toString().trim(); |     let gp = buf.toString().trim(); | ||||||
|     core.debug(`go env GOPATH :${gp}:`); |     core.debug(`go env GOPATH :${gp}:`); | ||||||
|     if (!fs.existsSync(gp)) { |     if (!fs.existsSync(gp)) { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Vladimir Safonkin
					Vladimir Safonkin