This commit is contained in:
Craig Raw 2024-04-18 09:45:58 +02:00
parent 2354b061a9
commit dd64c18c21

View file

@ -291,15 +291,15 @@ jlink {
} }
} }
tasks.jpackage.finalizedBy "addUserWritePermission" tasks.jlink.finalizedBy "addUserWritePermission"
task addUserWritePermission(type: Exec) { task addUserWritePermission(type: Exec) {
if(os.windows) { if(os.windows) {
commandLine 'icacls', "$buildDir\\jpackage\\Sparrow\\runtime\\legal\\*" commandLine 'icacls', "$buildDir\\image\\legal", '/grant', 'Users:(OI)(CI)F', '/T'
} else if(os.macOsX) { commandLine 'icacls', "$buildDir\\image\\legal\\*"
commandLine 'chmod', '-R', 'u+w', "$buildDir/jpackage/Sparrow.app/Contents/runtime/Contents/Home/legal" commandLine 'icacls', "$buildDir\\image\\legal\\java.base\\*"
} else { } else {
commandLine 'chmod', '-R', 'u+w', "$buildDir/jpackage/Sparrow/lib/runtime/legal" commandLine 'chmod', '-R', 'u+w', "$buildDir/image/legal"
} }
} }