mirror of
https://github.com/cryptomator/cryptomator.git
synced 2026-05-14 08:41:28 +00:00
add test script
This commit is contained in:
23
dist/win/signJarDlls.ps1
vendored
Normal file
23
dist/win/signJarDlls.ps1
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
<#
|
||||
1. Select jar file
|
||||
2. extract jar to own directory
|
||||
3. Sign everything
|
||||
4. Update dlls in the jar
|
||||
#>
|
||||
|
||||
New-Item -Path ".\extract" -ItemType Directory
|
||||
Get-ChildItem -Path "." -File *.jar | ForEach-Object {
|
||||
$jar = Copy-Item $_ -Destination ".\extract" -PassThru
|
||||
Set-Location -Path ".\extract"
|
||||
"Extracting jar $($jar.FullName)"
|
||||
jar --file=$($_.FullName) --extract
|
||||
Get-ChildItem -Path "." -Recurse -File "*.dll" | ForEach-Object {
|
||||
<# pipe into signtool, here we are just writing something into the file #>
|
||||
Set-Content -Path $_ -Value "Hello"
|
||||
jar --file=$($jar.FullName) --update $(Resolve-Path -Relative -Path $_)
|
||||
}
|
||||
Move-Item -Path $($jar.FullName) -Destination $_ -Force
|
||||
Remove-Item -Path ".\*" -Force -Recurse
|
||||
Set-Location -Path ".."
|
||||
}
|
||||
Remove-Item -Path ".\extract"
|
||||
Reference in New Issue
Block a user