cover

macOS by Tutorials

by Sarah Reichelt

Edition 2.0.1, August 2024
Copyright © 2024 Sarah Reichelt.

Notice of Rights

All rights reserved. No part of this book or corresponding materials (such as text, images, or source code) may be reproduced or distributed by any means without prior written permission of the copyright owner.

Notice of Liability

This book and all corresponding materials (such as source code) are provided on an “as is” basis, without warranty of any kind, express of implied, including but not limited to the warranties of merchantability, fitness for a particular purpose, and noninfringement. In no event shall the authors or copyright holders be liable for any claim, damages or other liability, whether in action of contract, tort or otherwise, arising from, out of or in connection with the software or the use of other dealing in the software.

Trademarks

All trademarks and registered trademarks appearing in this book are the property of their own respective owners.

Attribution

The author originally created portions of this work for the benefit of Kodeco, a community of developers who love to share their knowledge with the world. www.kodeco.com

License

By purchasing macOS by Tutorials, you have the following license:

  • You are allowed to use and/or modify the source code in macOS by Tutorials in as many apps as you want, with no attribution required.

  • You are allowed to use and/or modify all art, images and designs that are included in macOS by Tutorials in as many apps as you want, but must include this attribution line somewhere inside your app: “Artwork/images/designs: from macOS by Tutorials.

  • The source code included in macOS by Tutorials is for your personal use only. You are NOT allowed to distribute or sell the source code in macOS by Tutorials without prior authorization.

  • This book is for your personal use only. You are NOT allowed to sell this book without prior authorization, or distribute it to friends, coworkers or students; they would need to purchase their own copies.

All materials provided with this book are provided on an “as is” basis, without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose and non-infringement. In no event shall the authors or copyright holders be liable for any claim, damages or other liability, whether in an action of contract, tort or otherwise, arising from, out of or in connection with the software or the use or other dealings in the software.

All trademarks and registered trademarks appearing in this guide are the properties of their respective owners.

Preface

Welcome to the second edition of macOS by Tutorials.

The first edition of this book was published in April 2022 and a lot has changed in the Swift and SwiftUI world since then. macOS itself has also seen a lot of changes, with macOS Ventura and Sonoma, and there have been lots of improvements to Xcode.

In 2023, Kodeco (formerly raywenderlich.com) changed their approach from being similar to a library to becoming more like a school or college. Sadly, this meant that they were no longer going to publish books like this one. However, since it is now out-of-catalog, they have allowed me to take over the book and publish in my own name.

I’d like to acknowledge their assistance and pay tribute to the editors who worked with me on the original edition: Richard Critz, Audrey Tam and Ehab Amer. Special mention to Manda Frederick who was the book manager for the first edition and without whom, this book would never have been written. Also a big thank you to Matt Derrick, CEO of Kodeco, who agreed to and arranged the transfer of this book to me.

Every project in this book has been updated to macOS Sonoma and Xcode 15.

The major changes in this edition include:

  • The On This Day app uses NavigationSplitView instead of the older NavigationView.

  • On This Day implements the new Observation framework for its data.

  • The Time-ato app no longer imports the external LaunchAtLogin package but now uses Apple’s ServiceManagement library.

  • Creating an app intent in ImageSipper uses the new code-based system.

  • The workflow for distributing your app has been updated to reflect the changes in App Store Connect and Xcode.

I hope you enjoy this updated edition of macOS by Tutorials.

About the Author

I got hooked onto trying to make computers do what I told them a very long time ago and have never stopped loving it. I’m a keen evangelist for developing native Mac apps. When not at my computer, I love coffee, puzzles, reading and cooking — the day hasn’t started until the first cup of coffee is drunk and the crossword is done! — Sarah