Post

xed

I’ve been using this command for a while, but realize not everyone might know it.

xed the Xcode text editor invocation tool.
It let’s you open, create and handle Xcode related files in many ways, but the one that I predominantely use is:

1
$ xed .

When executed inside a folder with Xcode related files, it will open the “largest” Xcode document it finds.
Meaning, it will open the first *.xcworkspace, *.xcodeproj or Package.swift it can find, in this order of preference.

If you’re in a folder with a xcodeproj file, but no workspace, it will open the project. If the folder only contains a Package.swift, it will open the package. Generally, this will open the appropriate file for the folder of the project you’re working on.

This post is licensed under CC BY 4.0 by the author.