mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-26 23:28:14 +03:00
Do not treat bundles as executables in codesign check
Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
parent
258ba6da85
commit
da581e2b0e
1 changed files with 4 additions and 1 deletions
|
@ -33,7 +33,10 @@ func isAppExtension(_ path: String) -> Bool {
|
|||
}
|
||||
|
||||
func isExecutable(_ path: String) -> Bool {
|
||||
FileManager.default.isExecutableFile(atPath: path)
|
||||
let fm = FileManager.default
|
||||
var isDir: ObjCBool = false
|
||||
let exists = fm.fileExists(atPath: path, isDirectory: &isDir)
|
||||
return fm.isExecutableFile(atPath: path) && !isDir.boolValue && exists
|
||||
}
|
||||
|
||||
func codesign(identity: String, path: String, options: String = defaultCodesignOptions) throws {
|
||||
|
|
Loading…
Reference in a new issue