Skip to content

Commit

Permalink
fixed override script in usersapce
Browse files Browse the repository at this point in the history
  • Loading branch information
twocanoes committed Dec 28, 2023
1 parent 8acaf42 commit bdd6757
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 166 deletions.
5 changes: 5 additions & 0 deletions DefaultsOverride.swift
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@ public class DefaultsOverride: UserDefaults {
do {
let attributes = try FileManager.default.attributesOfItem(atPath: prefScriptPath)

if FileManager.default.isExecutableFile(atPath: prefScriptPath) == false {
TCSLogErrorWithMark("override script is not executible")

return
}
guard let ownerID=attributes[.ownerAccountID] as? NSNumber else {
TCSLogErrorWithMark("Could not get owner id")
return
Expand Down
2 changes: 1 addition & 1 deletion Profile Manifest/com.twocanoes.xcreds.plist
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<key>pfm_app_url</key>
<string>https://github.com/twocanoes/xcreds</string>
<key>pfm_description</key>
<string>XCreds 4.0 (6175) OAuth Settings</string>
<string>XCreds 4.0 (6176) OAuth Settings</string>
<key>pfm_documentation_url</key>
<string>https://twocanoes.com/knowledge-base/xcreds-admin-guide/#preferences</string>
<key>pfm_domain</key>
Expand Down
12 changes: 6 additions & 6 deletions xCreds.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1422,7 +1422,7 @@
buildSettings = {
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6175;
CURRENT_PROJECT_VERSION = 6176;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = UXP6YEHSPW;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1459,7 +1459,7 @@
buildSettings = {
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6175;
CURRENT_PROJECT_VERSION = 6176;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = UXP6YEHSPW;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1580,7 +1580,7 @@
CODE_SIGN_ENTITLEMENTS = "XCreds Login Overlay/XCreds_Login_Overlay.entitlements";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6175;
CURRENT_PROJECT_VERSION = 6176;
DEVELOPMENT_TEAM = UXP6YEHSPW;
ENABLE_HARDENED_RUNTIME = YES;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1617,7 +1617,7 @@
CODE_SIGN_ENTITLEMENTS = "XCreds Login Overlay/XCreds_Login_Overlay.entitlements";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6175;
CURRENT_PROJECT_VERSION = 6176;
DEVELOPMENT_TEAM = UXP6YEHSPW;
ENABLE_HARDENED_RUNTIME = YES;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1767,7 +1767,7 @@
CODE_SIGN_ENTITLEMENTS = XCreds/xCreds.entitlements;
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6175;
CURRENT_PROJECT_VERSION = 6176;
DEVELOPMENT_TEAM = UXP6YEHSPW;
ENABLE_HARDENED_RUNTIME = YES;
FRAMEWORK_SEARCH_PATHS = (
Expand Down Expand Up @@ -1809,7 +1809,7 @@
CODE_SIGN_ENTITLEMENTS = XCreds/xCreds.entitlements;
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 6175;
CURRENT_PROJECT_VERSION = 6176;
DEVELOPMENT_TEAM = UXP6YEHSPW;
ENABLE_HARDENED_RUNTIME = YES;
FRAMEWORK_SEARCH_PATHS = (
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -3,161 +3,4 @@
uuid = "94C20054-8AB3-42DB-93A7-A3026166D6FC"
type = "1"
version = "2.0">
<Breakpoints>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.ExceptionBreakpoint">
<BreakpointContent
uuid = "87ED3616-FF4A-47BF-A006-E1D3084D7FF0"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
breakpointStackSelectionBehavior = "1"
scope = "1"
stopOnStyle = "0">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "3CC83DB6-8385-48AA-A36B-2CEAF40C9B1C"
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "XCredsLoginPlugIn/LoginWindow/SignInWindowController.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "37"
endingLineNumber = "37"
landmarkName = "credentialsUpdated(_:)"
landmarkType = "7">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "50AFFF93-9DF9-4057-ABDD-D856FFC397B3"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "XCreds/MainController.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "113"
endingLineNumber = "113"
landmarkName = "run()"
landmarkType = "7">
<Locations>
<Location
uuid = "50AFFF93-9DF9-4057-ABDD-D856FFC397B3 - 8ed2d22f7e8200dc"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "closure #1 @Swift.MainActor () -&gt; () in closure #2 @Sendable (Foundation.Notification) -&gt; () in XCreds.MainController.run() -&gt; ()"
moduleName = "XCreds"
usesParentBreakpointCondition = "Yes"
urlString = "file:///Users/tperfitt/Documents/Projects/xcreds/XCreds/MainController.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "113"
endingLineNumber = "113"
offsetFromSymbolStart = "792">
</Location>
<Location
uuid = "50AFFF93-9DF9-4057-ABDD-D856FFC397B3 - 8ed2d22f7e8200dc"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "closure #1 @Swift.MainActor () -&gt; () in closure #2 @Sendable (Foundation.Notification) -&gt; () in XCreds.MainController.run() -&gt; ()"
moduleName = "XCreds"
usesParentBreakpointCondition = "Yes"
urlString = "file:///Users/tperfitt/Documents/Projects/xcreds/XCreds/MainController.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "113"
endingLineNumber = "113"
offsetFromSymbolStart = "832">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "68268C51-9AA3-4C9A-A569-1A3B5C30135F"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "XCreds/MenuItems.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "109"
endingLineNumber = "109"
landmarkName = "showSigninWindow()"
landmarkType = "7">
<Locations>
<Location
uuid = "68268C51-9AA3-4C9A-A569-1A3B5C30135F - f9e1d4a935df473b"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "XCreds.SignInMenuItem.showSigninWindow() -&gt; ()"
moduleName = "XCreds"
usesParentBreakpointCondition = "Yes"
urlString = "file:///Users/tperfitt/Documents/Projects/xcreds/XCreds/MenuItems.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "109"
endingLineNumber = "109"
offsetFromSymbolStart = "1176">
</Location>
<Location
uuid = "68268C51-9AA3-4C9A-A569-1A3B5C30135F - f9e1d4a935df473b"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "XCreds.SignInMenuItem.showSigninWindow() -&gt; ()"
moduleName = "XCreds"
usesParentBreakpointCondition = "Yes"
urlString = "file:///Users/tperfitt/Documents/Projects/xcreds/XCreds/MenuItems.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "109"
endingLineNumber = "109"
offsetFromSymbolStart = "1192">
</Location>
<Location
uuid = "68268C51-9AA3-4C9A-A569-1A3B5C30135F - f9e1d4a935df473b"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "XCreds.SignInMenuItem.showSigninWindow() -&gt; ()"
moduleName = "XCreds"
usesParentBreakpointCondition = "Yes"
urlString = "file:///Users/tperfitt/Documents/Projects/xcreds/XCreds/MenuItems.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "109"
endingLineNumber = "109"
offsetFromSymbolStart = "1184">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "4A6776F1-EBDE-4A41-8787-97186E8B1EF3"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "XCredsLoginPlugIn/LoginWindow/SignInWindowController.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "113"
endingLineNumber = "113"
landmarkName = "setupLoginAppearance()"
landmarkType = "7">
</BreakpointContent>
</BreakpointProxy>
</Breakpoints>
</Bucket>
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
<key>auth_mech_fixup.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>7</integer>
<integer>8</integer>
</dict>
<key>authrights.xcscheme_^#shared#^_</key>
<dict>
Expand All @@ -42,7 +42,7 @@
<key>test.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>8</integer>
<integer>7</integer>
</dict>
</dict>
<key>SuppressBuildableAutocreation</key>
Expand Down

0 comments on commit bdd6757

Please sign in to comment.