简体   繁体   English

是否有处理Android XML的emacs模式?

[英]Is there an emacs mode that handles Android XML?

If I open a .apk file with Emacs, it shows me the archive just fine, but if I select the AndroidManifest.xml file, all I get is gobbledegook, because the XML is Android's binary XML encoding. 如果我用Emacs打开一个.apk文件,它会向我显示存档,但是如果我选择AndroidManifest.xml文件,我得到的只是gobbledegook,因为XML是Android的二进制XML编码。

My google-fu has failed me in locating an emacs mode that understands Android Binary XML. 我的google-fu使我无法找到可以理解Android Binary XML的emacs模式。 Can anyone point me in the right direction? 谁能指出我正确的方向?

I don't believe any emacs XML mode would decode the binary XML format directly. 我不相信任何emacs XML模式都会直接解码二进制XML格式。 However, there is a small perl script that can turn the binary XML into readable XML here: http://code.google.com/p/android-random/source/browse/trunk/axml2xml/axml2xml.pl 但是,这里有一个小的Perl脚本,可以将二进制XML转换为可读XML: http : //code.google.com/p/android-random/source/browse/trunk/axml2xml/axml2xml.pl

When loading a binary XML in emacs, I select the whole buffer, and run 'shell-command-on-region', specifying axml2xml.pl as the command. 在emacs中加载二进制XML时,我选择整个缓冲区,然后运行“ shell-command-on-region”,并指定axml2xml.pl作为命令。 It's kludgy, but it works, for reading at least but not writing. 这很笨拙,但至少可以阅读但不能写作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM