I recently decided to do all my work in emacs and even though the learning speed is a bit slow, I thought I would share what I discoverd regarding editing the KIWI config files. Kiwi has the schema file for the elements and their attributes but unfortunately by default Emacs is unaware of it’s schema location. So first create a schema location file as below and save it.
<transformURI fromPattern="*.xml" toPattern="*.rnc"/>
<uri pattern=”*.kiwi” typeId=”KIWI”/>
<typeId id=”KIWI” uri=”/usr/share/kiwi/modules/KIWISchema.rnc”/>
I saved it as $HOME/.emacs.d/data/myschemas.xml. Now add this to your Emac’s init file for autoloading the nxml mode for kiwi files in addition to the xml files
(cons '("\\.\\(xml\\|kiwi\\|xsl\\|rng\\|xhtml\\)\\'" . nxml-mode)
and add this code for nxml mode to locate the kiwi schema file when you edit a kiwi config file
'(add-to-list 'rng-schema-locating-files (concat user-emacs-directory "data/myschemas.xml")))
Now have fun with Emacs, Kiwi and your openSUSE
Both comments and pings are currently closed.