All Projects → ArtSabintsev → Zephyr

ArtSabintsev / Zephyr

Licence: mit
Effortlessly synchronize UserDefaults over iCloud.

Programming Languages

swift
15916 projects

Projects that are alternatives of or similar to Zephyr

Defaults
Swifty and modern UserDefaults
Stars: ✭ 734 (+1.66%)
Mutual labels:  userdefaults, cocoapods, carthage, swift-package-manager
Swiftytexttable
A lightweight library for generating text tables.
Stars: ✭ 252 (-65.1%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Sync
JSON to Core Data and back. Swift Core Data Sync.
Stars: ✭ 2,538 (+251.52%)
Mutual labels:  sync, cocoapods, carthage
Web3.swift
A pure swift Ethereum Web3 library
Stars: ✭ 295 (-59.14%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Swipycell
Easy to use UITableViewCell implementing swiping to trigger actions.
Stars: ✭ 230 (-68.14%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Cloudcore
Framework that enables syncing between iCloud (CloudKit) and Core Data
Stars: ✭ 146 (-79.78%)
Mutual labels:  sync, cocoapods, swift-package-manager
Stepperview
SwiftUI iOS component for Step Indications.
Stars: ✭ 281 (-61.08%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Multipeer
📱📲 A wrapper for the MultipeerConnectivity framework for automatic offline data transmission between devices
Stars: ✭ 170 (-76.45%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Tweetextfield
Lightweight set of text fields with nice animation and functionality. 🚀 Inspired by https://uimovement.com/ui/2524/input-field-help/
Stars: ✭ 421 (-41.69%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Keyboardshortcuts
Add user-customizable global keyboard shortcuts to your macOS app in minutes
Stars: ✭ 500 (-30.75%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Openssl
OpenSSL package for SPM, CocoaPod, and Carthage, for iOS and macOS
Stars: ✭ 515 (-28.67%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Amplitude Ios
Native iOS/tvOS/macOS SDK
Stars: ✭ 216 (-70.08%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Aksidemenu
Beautiful iOS side menu library with parallax effect. Written in Swift
Stars: ✭ 216 (-70.08%)
Mutual labels:  cocoapods, carthage, swift-package-manager
L10n Swift
Localization of the application with ability to change language "on the fly" and support for plural form in any language.
Stars: ✭ 177 (-75.48%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Sablurimageview
You can use blur effect and it's animation easily to call only two methods.
Stars: ✭ 538 (-25.48%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Corestore
Unleashing the real power of Core Data with the elegance and safety of Swift
Stars: ✭ 3,254 (+350.69%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Cdmarkdownkit
An extensive Swift framework providing simple and customizable markdown parsing.
Stars: ✭ 158 (-78.12%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Kvkcalendar
A most fully customization calendar and timeline library for iOS 📅
Stars: ✭ 160 (-77.84%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Functionkit
A framework for functional types and operations designed to fit naturally into Swift.
Stars: ✭ 302 (-58.17%)
Mutual labels:  cocoapods, carthage, swift-package-manager
Swiftframeworktemplate
A template for new Swift iOS / macOS / tvOS / watchOS Framework project ready with travis-ci, cocoapods, Carthage, SwiftPM and a Readme file
Stars: ✭ 527 (-27.01%)
Mutual labels:  cocoapods, carthage, swift-package-manager

Zephyr 🌬️

Effortlessly sync UserDefaults over iCloud

Swift Support Platform CocoaPods SwiftPM Compatible


About

Zephyr synchronizes specific keys and/or all of your UserDefaults over iCloud using NSUbiquitousKeyValueStore.

Zephyr has built in monitoring, allowing it to sync specific keys in the background as they change.

For the latest updates, refer to the Releases tab.

Features

  • [x] CocoaPods and SwiftPM Support
  • [x] Syncs specific UserDefaults keys or all of your UserDefaults.
  • [x] Background monitoring and synchronization between UserDefaults and NSUbiquitousKeyValueStore
  • [x] Detailed Logging

Installation Instructions

Swift Version Branch Name Will Continue to Receive Updates?
5.1+ master Yes
5.0 swift5.0 No
4.2 swift4.2 No
4.1 swift4.1 No
3.2 swift3.2 No
3.1 swift3.1 No

CocoaPods

pod 'Zephyr' # Swift 5.1+
pod 'Zephyr', :git => 'https://github.com/ArtSabintsev/Zephyr.git', :branch => 'swift5.0' # Swift 5.0
pod 'Zephyr', :git => 'https://github.com/ArtSabintsev/Zephyr.git', :branch => 'swift4.2' # Swift 4.2
pod 'Zephyr', :git => 'https://github.com/ArtSabintsev/Zephyr.git', :branch => 'swift4.1' # Swift 4.1
pod 'Zephyr', :git => 'https://github.com/ArtSabintsev/Zephyr.git', :branch => 'swift3.2' # Swift 3.2
pod 'Zephyr', :git => 'https://github.com/ArtSabintsev/Zephyr.git', :branch => 'swift3.1' # Swift 3.1

Swift Package Manager

.Package(url: "https://github.com/ArtSabintsev/Zephyr.git", majorVersion: 3)

Manual

  1. Download Zephyr
  2. Copy Zephyr.swift into your project.

Setup

Turn on iCloud Sync in Xcode

In Xcode, open your app's project/workspace file:

  • Click on your Project
  • Click on one of your Targets
  • Click on Capabilities
  • Turn on iCloud syncing
  • Under Services, make sure to check Key-value storage
  • Repeat for all Targets (if necessary)

How to turn on iCloud Key Value Store Syncing

Integrate Zephyr into your App

Before performing each sync, Zephyr automatically checks to see if the data in UserDefaults or NSUbiquitousKeyValueStore is newer. To make sure there's no overwriting going on in a fresh installation of your app on a new device that's connected to the same iCloud account, make sure that your UserDefaults are registered BEFORE calling any of the Zephyr methods. One way to easily achieve this is by using the UserDefaults Register API.

Sync all UserDefaults

Zephyr.sync()

Sync a specific key or keys (Variadic Option)

Zephyr.sync(keys: "MyFirstKey", "MySecondKey", ...)

Sync a specific key or keys (Array Option)

Zephyr.sync(keys: ["MyFirstKey", "MySecondKey"])

Add/Remove Keys for Background Monitoring (Variadic Option)

Zephyr.addKeysToBeMonitored(keys: "MyFirstKey", "MySecondKey", ...)
Zephyr.removeKeysFromBeingMonitored(keys: "MyFirstKey", "MySecondKey", ...)

Add/Remove Keys for Background Monitoring (Array Option)

Zephyr.addKeysToBeMonitored(keys: ["MyFirstKey", "MySecondKey"])
Zephyr.removeKeysFromBeingMonitored(keys: ["MyFirstKey", "MySecondKey"])

Toggle Automatic Calling of NSUbiquitousKeyValueStore's Synchronization method

Zephyr.syncUbiquitousKeyValueStoreOnChange = true // Default
Zephyr.syncUbiquitousKeyValueStoreOnChange = false // Turns off instantaneous synchronization

Debug Logging

Zephyr.debugEnabled = true // Must be called before sync(_:)
Zephyr.sync()

Sample App

Please ignore the Sample App as I did not add any demo code in the Sample App. It's only in this repo to add support for Carthage.

Created and maintained by

Arthur Ariel Sabintsev

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].