Giter VIP home page Giter VIP logo

lsunusedresources's Introduction

LSUnusedResources

A Mac App to find unused images and resources in an Xcode project. It is heavily influenced by jeffhodnett‘s Unused, but Unused is very slow, and the results are not entirely correct. So I made some performance optimization, the search speed is more faster than Unused.

Example

LSMessageHUD Example1

Usage

It's an useful utility tool to check what resources are not being used in your Xcode projects. Very easy to use:

  1. Click Browse.. to select a project folder.
  2. Click Search to start searching.
  3. Wait a few seconds, the results will be shown in the tableview.

Feature

Check Ignore similar name to ignore the resources which referenced by string concatenation, regex: ([-_]?\d+).

For example:

You import some resources like:

icon_tag_0.png
icon_tag_1.png
icon_tag_2.png
icon_tag_3.png

icon_title-0.png
icon_title-1.png
icon_title-2.png

icon_test0.png
icon_test1.png
icon_test2.png

And using in this way:

NSInteger index = random() % 4;
UIImage *img0 = [UIImage imageNamed:[NSString stringWithFormat:@"icon_tag_%d", index]];
	
// Or
UIImage *img1 = [self createImageWithPrefix:@"icon_title" concat:@"-" andIndex:index];

// Or
UIImage *img2 = [self createImageWithPrefix:@"icon_test" andIndex:index];

icon_tag_x.png, icon_title-x and icon_testx will be considered to be used, should not be shown as unused resource.

Installation

How it works

  1. Get resource files (default: [imageset, jpg, png, gif]) in these folders [imageset, launchimage, appiconset, bundle, png].
  2. Use regex to search all string names in code files (default: [h, m, mm, swift, xib, storyboard, strings, c, cpp, html, js, json, plist, css]).
  3. Exclude all used string names from resources files, we get all unused resources files.

Requirements

Requires OS X 10.7 and above, ARC.

lsunusedresources's People

Contributors

dimohamdy avatar ligr avatar nathanwhy avatar pedrovieira avatar remlostime avatar tinymind avatar tinytoy avatar tomatoeggs avatar wangwanjie avatar wmellon avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.