[HowTo] Get your Themes with cmupdater [Updated 28/10/2009]
Hey Guys!
All you have to do is put a additional file under /system/framework (so the Updater knows the Theme Version your running on) and create your own MetadataFile for Theme Support.
You can also create a Big MetadataFile with all the Updates in there, but thats a whole work to keep it up to date.
Take a look at the wiki, how the JSON-File has to look, and how the update will work:
http://code.google.com/p/cyanogen-up...ONMetadataFile
When you have questions: Just ask
Hope you like it
Update 28/10/2009:
CM-Updater 4.5 is out.
Get it here:
http://cyanogen-updater.googlecode.c...pdater_4.5.apk
Update 09/09/2009:
Added a HowTo
Update 08/09/2009:
CM-Updater 4.1 is out:
- Fixed Bug when changing orientation while Barcodescanning
- Fixed Bug with MD5SUM to Pad the String to 32chars
- UpdateFolder can now be changed (i think its beta
)
Suggestion for all Theme Developers(cause some host their themes on one click hosters):
Create a google code Project to host your themes and your JSON.
You can put up to 2gb Files on there and you have direct downloads.
For Barcodes use this link(creates permalinks):
http://qrcode.kaywa.com/
HowTo:
When you want to Use the Theme Update Feature, youn have to configure a Theme Server first. I haven't included one, because each ThemeDev has its own Theme JSON File.
Search your Favourite Theme Thread @ XDA and see, if the Designer already made it cm-updater compatible. If not ask him if he can do so and point him to this Thread.
If its compatible, just go to Settings-->Themes-->Theme Update Server, and enter the URL (must be a URL to a file called *.json) or just scan a Theme Barcode if the ThemeDev provided one. The Barcodescanning is the same as entering it manually, but it saves work so you don't have to type in the url.
The next Time you do a "Check now" the ThemeUpdaterServer File will be scanned (also the Rom Updates) and if the Theme matches some criterias (see below), it will show up in the App under Themes. All you have to do now, is download the File and hit "Apply Now".
When you are complaining about, the Themes and Roms are showing up even tough you already installed it, just disable the "Show all Updates" Option. When this is enabled, you will always see every Update(with a few limitations as described above). When you disable this feature, you will probably only see Updates.
How the Updater works (Themes):
Theme Developers put a File called
/system/framework/themes.theme
in their Themepackages, to tell the Update you are running a Theme with this name and this Version.(The Path is configurable)
When there is no themes.theme File present, the App assumes a Wildcard for Theme Checking (will come to this later).
When any of the described checks don't pass, the Update is Discarded and the App proceeds with checking the next Update in the List.
When you do now an Updatecheck, first the Rom Provided in the JSON File (Theme Update Server) must match the Rom your running. This is because a Theme is always designed for a specific Version of a Rom, and this is a Securityfeature that you can not mess up your System.
When your Rom Matches, the next thing from the JSON that gets compared is the Theme Name.
This must either match the Theme Name from the themes.theme, or if this File is not Present or you have the "Show all Theme Updates" Option enabled, the Wildcard is used. So this Updates will always show up, so you can install a Theme, if you dont have one installed.
Next thing is the Version. If Wildcard(no themes.theme File or Show All Updates enabled) is used, the Version is not compared. Otherwise its compared against the Version from the themes.theme, so you will only see updates for your Theme and no older Versions.
The last thing that must match is the branch. Its either Stable or Experimental. It depends on your Configuration (Show Experimental Builds), if this update shows up or not.
When your Update is not showing up, connect your Phone via USB Cable and do an
Code:
adb logcat | grep "<CM-Updater>"
You will see the Output from the App, and the Reason why an Update is discarded. It can be helpful for Theme devs to test their own Jsons.