Contents

jeffctown/xcutility

xcutility is a tool to find and delete unused files from Xcode projects.

Installation

Using a pre-built package:

You can install xcutility by downloading xcutility.pkg from the latest GitHub release and running it.

Compiling from source:

You can also build from source by cloning this project and running make install (Xcode 10.2 or later).

Quick Start

  • Find Swift files not referenced in any Xcode projects:

* Find Objective C files not referenced in any Xcode projects:
  • Find Swift & Objective C files not referenced in any Xcode projects:

* Find Swift files not compiled in any Xcode projects:
  • Find Objective C files not compiled in any Xcode projects:

* Find Swift & Objective C files not compiled in any Xcode projects:

Usage

Help

$ xcutility help
Available commands:

   all       Find files that are not built or referenced in any Xcode projects
   help      Display general or command-specific help
   norefs    Find files that are not referenced in any Xcode projects
   unbuilt   Find files that are referenced in Xcode but not built in any build phases
   version   Display the current version of xcutility

Unreferenced Files

Find Files that are Unreferenced by any Xcode Projects in the Current Directory
xcutility norefs
Find Files that are Unreferenced by any Xcode Projects In a Specific Path
xcutility norefs --path ~/MySweetSweetApp/
Find Files With a Certain Extension that are Unreferenced by any Xcode Projects
xcutility norefs --extensions .swift
Find Only Files With Multiple Extensions that are Unreferenced by any Xcode Projects
xcutility norefs --extensions .swift,.h,.m
Find And Delete Files With Multiple Extensions that are Unreferenced by any Xcode Projects
xcutility norefs --extensions .swift,.h,.m --delete
Find Unreferenced Files Verbosely
xcutility norefs --verbose

Find Unreferenced Files Combined Usage

xcutility norefs --path ~/MySweetSweetApp/ --extension .swift,.h,.m --verbose --delete

Unbuilt Files

Find Files that are not built by any Xcode Project Build Phases in the Current Directory
xcutility unbuilt
Find Files that are not built by any Xcode Project Build Phases in a specific path
xcutility unbuilt --path ~/MySweetSweetApp/
Find Files With a Certain Extension that are not built by any Xcode Projects Build Phases
xcutility unbuilt --extensions .swift
Find Only Files With Multiple Extensions that are not built by any Xcode Projects Build Phases
xcutility unbuilt --extensions .swift,.h,.m
Find And Delete Files With Multiple Extensions that are not built by any Xcode Projects Build Phases
xcutility unbuilt --extensions .swift,.m --delete
Find Unbuilt Files Verbosely
xcutility unbuilt --verbose

Find Unbuilt Files Combined Usage

xcutility unbuilt --path ~/MySweetSweetApp/ --extension .swift,.m --verbose --delete

License

xcutility is released under the MIT license.

Package Metadata

Repository: jeffctown/xcutility

Default branch: master

README: README.md