Originally Posted by the1dynasty
is there a "How to..." on using this script so i can update my themes to newer ROMs and/or porting them?? i learn fast but i don't have much time to figure this out on my own... so any help is appreciated!
btw, i just got a computer setup to theme... so i can do the basics right now of that...
I tried to make those READMEs rather specific... ^^; What else can I offer?
I did start
on HCS, but didn't get very far. I can summarise what I've done so far. You've already seen the scripts I put on github
? So what I did went something like this...
to put all the packages from your theme in the $PACKAGES array:
Create a new git repo:
mkdir -p theme/dcs/codename
Extract the Codename ROM:
Tell git to make note of every directory that will contain theme changes, then make an initial commit:
git add framework-res SystemUI Camera Contacts Gmail Launcher2 Mms PhaseBeam Phone Settings Talk
git commit -m 'Initial commit'
That extracts every package referenced in the $PACKAGES array from the Codename ROM, and creates a basic unthemed state for us to work with. Next, we want to see what you changed in HCS. So create a new branch for HCS:
git branch hcs
git checkout hcs
Extract your theme:
And now you can type
to see what changed between your theme and Codename. There about 8500 unstaged changes. -_- Too much to process on the command line. We can use git gui
to view the differences graphically, but git gui only shows 5000 unstaged changes by default, which doesn't help us. So do this:
git config --add gui.maxfilesdisplayed 65535
Now you're looking at a list of every unstaged change! The top left shows every modified or untracked file. Modified files have a blue icon; untracked files have a white icon. You only need to worry about the modified files.
Scroll waaaaay down to where you see modified files in framework-res. Click on any one. If it's an image (anything ending in *.png), you probably want to include it. You can do that by selecting Commit -> Stage To Commit
from the menu. Files staged for commit will appear in the lower-left corner.
You have several hundred modified images in framework-res alone, so go ahead and select them all (click the first image, then shift-click the last image) and stage them for commit.
What's left over are XML files, and these are trickier. There are some changes that are useful, like colour changes:
And some changes that are "useless", such as stuff that should be left up to the ROM to decide, like resource names or language translations:
You'll have to decide for yourself what's useful and useless, and stage only the useful changes for commit.
Some XML files may have some lines that are useful, and some lines that are useless! You can stage individual lines for commit by highlighting the line(s) in the upper-right box, right-clicking, then selecting Stage Line for Commit
from the context menu.
Once you have staged every useful change in framework-res for commit, type a description into the lower-right box, then click the Commit
I recommend doing a separate commit for each package (i.e. one for framework-res, one for SystemUI, one for Settings, etc.) to keep things simple. The more complex a commit is, the harder it will be to resolve conflicts when you try to cherry-pick them to another ROM! (For more on cherry-picking, refer to my README for gingercream_cm9