Open user8446 opened 2 years ago
This is due to an issue with the module being deployed with a file called installed. The module uses that file to indicate if the required platform specific binary has been copied to the correct location. Right now, the MacOS version is present causing issues on Windows. If you run this command it will remove the bad files so it can import correctly.
$module = Get-Module PowerGit -ListAvailable | sort version -Descending | select -exp modulebase -First 1
rm $module\Assemblies\installed, $module\Assemblies\libgit2-*
@felixfbecker can we please get this resolved? Instead of copying the file in the appropriate place PowerShell 7 added a unmanaged native library resolver that handles this work for you. Here is the link for more information: https://docs.microsoft.com/en-us/powershell/scripting/dev-cross-plat/writing-portable-modules?view=powershell-7.2#dependency-on-native-libraries
Just want to say thanks for researching and the workaround @ThomasNieto
@felixfbecker Hello,
After the 0.8.1 update
Copy-GitRepository
throws:Downgrading to 0.7.1 works as expected
Edit: Repro'ed with all versions after 0.8.1 as well