Skip to content

Latest commit

 

History

History
36 lines (18 loc) · 1.29 KB

README.md

File metadata and controls

36 lines (18 loc) · 1.29 KB

Prune Localizations

This plugin removes unused localized files from your app.

Localized resources provided by third parties increase the size of your app and keeping resources your app will never use only bloats it.

##Requirements

Requires CocoaPods 0.36

Installation

$ gem install cocoapods-prune-localizations

Usage

In your Podfile, add this line:

plugin 'cocoapods-prune-localizations'

Localizations will be inferred from your project.

or if you would prefer to specify the localizations:

plugin 'cocoapods-prune-localizations', {:localizations => ["en", "es"]}

This will keep the English and Spanish localizations in the Pods. Modify the localizations to your needs.

##How it works

The plugin traverses the resources provided by Pods and removes references in the Xcode project of .lproj files that don't match the list provided.

A special case are .bundle file references because they are a package of different resources. As such, if any localized files are found unnecessary, a new bundle is created without those files and replaces the original in the project. These new bundles are located at Pods/Pruned Localized Bundles

Note: No file is actually removed from your computer, only references to them in the project