mirror of
				https://github.com/shivammathur/setup-php.git
				synced 2025-10-31 07:16:22 +07:00 
			
		
		
		
	Fix adding Import-Module command to the profile in Install-PSPackage
This commit is contained in:
		| @ -166,10 +166,10 @@ Function Install-PSPackage() { | ||||
|     Expand-Archive -Path $zip_file -DestinationPath $bin_dir -Force | ||||
|   } | ||||
|   Import-Module $module_path | ||||
|   Add-ToProfile $current_profile "$package-search" "Import-Module $module_path" | ||||
|  | ||||
|   if($null -eq (Get-Command $cmdlet -ErrorAction SilentlyContinue)) { | ||||
|     Install-Module -Name $package -Force | ||||
|   } else { | ||||
|     Add-ToProfile $current_profile "$package-search" "Import-Module $module_path" | ||||
|   } | ||||
| } | ||||
|  | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 Shivam Mathur
					Shivam Mathur