Created
April 29, 2013 11:20
-
-
Save xupefei/5481027 to your computer and use it in GitHub Desktop.
CatSystem2 layer_rename.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#target photoshop | |
app.bringToFront(); | |
var layers = activeDocument.layers; | |
for (var i = 0; i < layers.length; i++) { | |
if(layers[i].name[0] == '[') | |
layers[i].name = layers[i].name.replace(".png", ""); | |
else | |
layers[i].name = "@(" + layers[i].name.replace(".png", "") + ")"; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment