Hello Guys,
When ever designer gives you a set of drawables, we need to manually copy them to all the respective folders (mdpi, hdpi, xhdpi etc). But, how about writing a script where you mention source folder and destination( project ) folder which does all the copying and replacing for you. This script is written for Mac.
Download the script from here.
Follow the below instructions after that
When ever designer gives you a set of drawables, we need to manually copy them to all the respective folders (mdpi, hdpi, xhdpi etc). But, how about writing a script where you mention source folder and destination( project ) folder which does all the copying and replacing for you. This script is written for Mac.
Download the script from here.
Follow the below instructions after that
- Copy script.sh into any of
the folder
- Open terminal – Add some
permissions to make script.sh as executable
- Navigate
to the folder where script.sh resides
- Type in
- sudo chmod 700 script.sh
- Prompts
for Sys password – Enter it
- Your file
is marked as executable
- Note:
- Do this
step only on first time
- Reference
- In terminal
navigate to the folder in which script.sh resides
- Type in - ./script.sh
o Copies
all resources in drawable foder of source to mipmap folder of destination.
o Do
not forget to change the source and destination path in script.sh.
Note:
- Open script.sh and set your source and destination folders properly.
- Currently script does not support spaces in folders.
Hope this saves some
time for you.
Cheers,
Sree
No comments:
Post a Comment