Snorlax
The ultimate lazy library. An example for being a good library citizen in Swift.
Install / Use
/learn @tryswift/SnorlaxREADME
Snorlax
The ultimate lazy library. Can cause a thread to sleep for a random amount of time.
This looks useless, what is this really?
Snorlax is a good citizen in the Swift ecosystem. It's a reference implementation to support as many different platforms as possible.
Snorlax currently supports the following platforms:
- Mac OS X
- iOS
- tvOS
- watchOS
- Linux
Using the following Package Managers:
- CocoaPods
- Carthage
- Swift Package Manager
- Adding as an Xcode Subproject
Feel free the look at the commit history or browse the documentation to see how to create a library:
Can I try installing it?
Sure, use your favorite package manager. Please note the two different versions:
- Odd minor versions (eg -
0.1.0) require no dependencies. The latest one is0.1.1. - Even minor versions (eg -
0.2.0) has dependencies. The latest one is0.2.1. Currently, these dependencies don't support all the platforms properly (WIP).
You can see examples at Snorlax Samples
CocoaPods
Add Snorlax to your pod file and run pod install:
# CocoaPods
pod 'Snorlax', '~> 0.1.0'
Carthage
Add Snorlax to your Cartfile (package dependency) or Cartfile.private
(development dependency):
github "tryswift/Snorlax" ~> 0.1.0
Swift Package Manager
Add to your Package.swift dependencies:
import PackageDescription
let package = Package(
// ... your project details
dependencies: [
// As a required dependency
.Package(url: "ssh://git@github.com/tryswift/Snorlax.git", majorVersion: 0)
],
testDependencies: [
// As a test dependency
.Package(url: "ssh://git@github.com/tryswift/Snorlax.git", majorVersion: 0)
]
)
Manually as an Xcode Subproject
TODO
Contributions
See CONTRIBUTING. Documentation improvements and translations are welcomed!
Related Skills
node-connect
349.0kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
109.4kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
349.0kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
349.0kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
