Enable ARC for Cocoa startup, local network permission probes, FinderSync
services and XPC, the File Provider service, and Sparkle.
Keep application startup in a scoped autorelease pool, balance opaque XPC
references, and detach native delegates before their C++ owners disappear.
Add regression coverage for native object lifetime, queued replies,
cancellation, teardown, and late callbacks.
Assisted-by: Codex:GPT-6
Signed-off-by: Claudio Cambra <[email protected]>
Require ARC for new Objective-C sources while preserving manual reference
counting in existing files until they are migrated separately.
Assisted-by: Codex:GPT-6
Signed-off-by: Claudio Cambra <[email protected]>
Broaden the clang-format requirement beyond ./src to all C++ source
files, and add a mandatory run-clang-tidy -fix pass that must report
no further changes before a task is considered done.
Signed-off-by: Matthieu Gallien <[email protected]>
Co-Authored-By: Claude Sonnet 5 <[email protected]>
Replace the UNIX domain socket IPC between the desktop client and the
macOS Finder Sync extension with Apple's native XPC mechanism.
Motivation:
The socket-based approach used a custom line-based text protocol over
UNIX domain sockets, requiring manual parsing, hand-managed connection
lifecycles, and offering no built-in security validation. XPC is Apple's
recommended IPC for app extensions, providing type-safe method dispatch,
automatic lifecycle management, and code-signing verification.
Architecture:
Two Objective-C protocols define a bidirectional XPC contract:
- FinderSyncAppProtocol (extension -> app): file/folder status queries,
context menu requests, and command execution.
- FinderSyncProtocol (app -> extension): path registration, status badge
pushes, localized string delivery, and menu item streaming.
On the app side, FinderSyncXPC manages the XPC listener and broadcasts
to all connected extensions. FinderSyncService implements the app
protocol by adapting calls to the existing cross-platform SocketApi
business logic via a ResponseCapturingListener, avoiding any
reimplementation of sync status or menu command handling. Thread safety
across XPC and Qt threads is ensured via QMetaObject::invokeMethod with
blocking queued connections.
On the extension side, FinderSyncXPCManager handles connection setup,
reconnection with exponential backoff, and status caching. FinderSync
(the FIFinderSync subclass) delegates all communication to the XPC
manager and bridges Finder's synchronous menuForMenuKind: API to XPC's
async model using NSCondition.
Security is enforced through macOS entitlements (mach-register and
mach-lookup for the FinderSyncService name) and a server-side command
whitelist that restricts executable commands to a predefined set.
Removed:
- NCDesktopClientSocketKit framework (LocalSocketClient, LineProcessor)
- FinderSyncSocketLineProcessor and FileProviderSocketLineProcessor
- FileProviderSocketServer and FileProviderSocketController
Resolves#9430
Signed-off-by: Iva Horn <[email protected]>
- Changed KDE Craft build directory of mac-crafter to enable Spotlight indexing
- Copy debug symbol bundles into build directories
- Flatten the broken debug symbol bundles produced by KDE Craft
- Updated AGENTS.md
Signed-off-by: Iva Horn <[email protected]>
- Derived data directory ".xcode" for Xcode workspace in project root.
- Mac crafter build directory ".mac-crafter" in project root.
- Added all Swift packages and Xcode projects to workspace.
- Added some important top-level files and other directories.
- Removed obsolete Xcode workspace in shell integration directory.
- Removed obsolete OwnCloudFinderSync folder.
- Updated AGENTS.md.
- Updated README.md.
- Renamed NextcloudDev scheme to Nextcloud Developer Client.
- Fixed Xcode not being abled to resolve breakpoints because the dSYM files are in a dot-directory which is not indexed by Spotlight. mac-crafter now copies the debug symbols manually into the app bundle so they are found.
Signed-off-by: Iva Horn <[email protected]>