• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
11

Photoshop: Ability to remove/purge layers not used in any Layer Comp

Community Beginner ,
Apr 01, 2011 Apr 01, 2011

Copy link to clipboard

Copied

I work extensively with deeply-layered screen-resolution documents (ie. mock-ups). I like to keep my history -- or at least some of it -- of experiments as Layer Comps. But every now and again, these PSDs will get prohibitively heavy.

So what I'm looking for is a command, or script, that will let me purge any layer which is not visible in ANY Layer Comp in the file.

Does such a script exist?
Idea No status

Views

382

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
8 Comments
LEGEND ,
Jun 01, 2011 Jun 01, 2011

Copy link to clipboard

Copied

Rasmus, I'm not sure if this will help. Perhaps I did not understand your issue correctly.

But if you need simply remove all non-viewed Layers in a document, then you can do this by choosing Layer Palate Option and selecting the option 'Delete Hidden Layers'.

Hope this helps 😉

Votes

Translate

Translate

Report

Report
Community Beginner ,
Jun 01, 2011 Jun 01, 2011

Copy link to clipboard

Copied

Thanks, but I meant exactly what I said :-)

ie.:
- search through all Layer Comps, building a total list of used layers
- finally, delete any layers not used in any Layer Comp

I dug a bit and found a couple of scripts that users made which purportedly do this. I wasn't able to get any of them to work. Should be a simple job and would be very helpful as a PS feature. I often need it.

Votes

Translate

Translate

Report

Report
LEGEND ,
Oct 12, 2011 Oct 12, 2011

Copy link to clipboard

Copied

And how about one better? Why not be able to set a setting on your PSD that trims all layers to size. That way the app automatically removes blank layer margin pixels. They're not necessary in smart comps most often.

But basically what the guy wants is a way to optimize the PSD as it saves, because there's PSDs that weigh about let's say 1GB, and if it was all trimmed and optimized, then it may be...say 200MB. Some people's workflow (such as mine) utilizes a lot of different extra layers that we turn on and off or use to make layer masks. Then 50GB of your harddrive goes to 50 Psds. Not that I don't gladly store all my PSDs for future use, but after a few years of work, it becomes an issue.
Just imagine the 50GB cache of a person's PSD files gets to 5 or even 10GB instead of the 50.

Is there a quick way to crop/minimize layers?

Votes

Translate

Translate

Report

Report
Valorous Hero ,
Mar 11, 2012 Mar 11, 2012

Copy link to clipboard

Copied

I have just written a script here to do this...
http://forums.adobe.com/thread/973796...

Votes

Translate

Translate

Report

Report
LEGEND ,
Jan 02, 2015 Jan 02, 2015

Copy link to clipboard

Copied

Scripts scare me, so I found a really freaking easy workaround:

1. Filter layers list to Attribute = Not Visible
2. Select all the matching layers
3. Cycle through all layer comps
4. Layers still selected aren’t used in any layer comp

Delete the layers that are still selected. Bingo bango. With keyboard shortcuts for navigating layer comps, this takes like 7 seconds or something.

Votes

Translate

Translate

Report

Report
LEGEND ,
Mar 08, 2015 Mar 08, 2015

Copy link to clipboard

Copied

Brilliant workaround.
Thanks!

Votes

Translate

Translate

Report

Report
New Here ,
Aug 18, 2015 Aug 18, 2015

Copy link to clipboard

Copied

I would still prefer something built into Photoshop without a workaround or a script.

Votes

Translate

Translate

Report

Report
LEGEND ,
Sep 28, 2015 Sep 28, 2015

Copy link to clipboard

Copied

LATEST
Really smart. Thanks!

Votes

Translate

Translate

Report

Report