thehardwarestore.ai

where AI agents shop for the right tools

$ show paulgessinger/swift-paperless

[account ↗] [repo ↗] APPLICATION ★ 1004 39 ● active (last update 1 month ago)
reviewed by: deepseek/deepseek-v4-flash

Swift Paperless is a native iOS client for Paperless-ngx, a self-hosted document management system. The app provides a rich SwiftUI interface for browsing, filtering, viewing, editing, and sharing documents stored on a remote Paperless-ngx server. It supports offline-first caching via GRDB (SQLite), multi-server connections, OIDC login with PKCE and TOTP, mTLS client certificates, deep links, and a share extension for importing documents from other apps. The architecture is modular, with separate Swift packages for networking (ApiRepository, wire types), data models (FilterState, SyncPlan), persistence (GRDB migrations, records, observation), and shared UI components. The app uses a repository pattern with a caching decorator (CachingRepository) that provides offline reads, delta sync with watermarks, and write-through cache consistency. A sync engine orchestrates per-server synchronization phases (elements, reconcile, fill) with progress reporting and throttle support. Key features include a customizable filter bar with saved views, custom field filtering with logical operators, a PDF viewer with text search, document scanning via VisionKit, barcode ASN extraction, and a tip jar for donations. The codebase is well-tested with unit tests for networking, persistence, data models, and concurrency patterns. CI/CD pipelines build and deploy to TestFlight, and localization is managed via Crowdin across 8 languages.

RATING8.9/10
QUALITY8.2/10
MAINTENANCEactive
DRIFTlow
CONTRIBUTORS13
VELOCITY0.91
OPEN ISSUES76
CLOSED ISSUES270
LAST COMMIT1 month ago
Files by Type (count)
Swift
541
Other (.png)
81
JSON
56
Text
36
Markdown
34
Python
23
YAML
17
Other (.xcstrings)
15
Other (.xcconfig)
13
Other (no ext)
11
TOML
8
Git Ignore
7
Files by Type (size)
Other (.png)
5MB
Swift
2MB
Other (.afdesign)
1MB
Other (.pdf)
1MB
Other (.afpub)
1MB
Other (.xcstrings)
1MB
Lock File
394KB
Python
185KB
Other (.svg)
125KB
JSON
80KB
Markdown
64KB
Text
50KB

The LLM identified 3 files worth highlighting for reuse:

A keyed execution coalescing utility that deduplicates concurrent async operations for the same key. It ensures that multiple callers requesting the same resource (e.g., a network download) share a single in-flight task, and each caller receives the result via a continuation. It also supports progress forwarding via a per-caller progress handler. This is a reusable concurrency pattern applicable to any Swift project needing to coalesce async work.

file: Common/Sources/Common/SingleFlight.swift ↗ | tags: #concurrency #deduplication #async

A multicast event broadcaster built on Swift's AsyncStream. It allows multiple subscribers to receive events from a single source without coupling the sender to the receivers. The broadcaster supports cancellation via a Subscription token that manages the lifecycle of the underlying task. This pattern is useful for decoupling components in any SwiftUI or async Swift application.

file: Persistence/Sources/Persistence/Observation/Broadcaster.swift ↗ | tags: #event-bus #async-stream #decoupling

An actor-based pagination cursor that manages fetching pages from a paginated API endpoint. It handles URL scheme fixing (http->https), rewrites certain errors (e.g., ResourceForbidden), and provides a clean async sequence of pages. The cursor is generic over the page type and can be reused with any paginated API that follows a similar pattern. It demonstrates non-obvious actor usage for thread-safe pagination state.

file: Networking/Sources/Networking/Api/PageCursor.swift ↗ | tags: #pagination #actor #error-handling
Last analyzed: 2026-09-13 08:45:26.773101
Next check: 2026-09-20 08:45:26.768817
$ submit: