Repository of reference document (the "cheat sheet") for Git Quick Reference android application. It is written in XML to make it easier to edit and validate.
The quickref.xml document is pretty much self explainatory. RELAX NG schema describing valid XML document can be found in the quickref.rng. Here is sniplet of the XML document
<quickref>
<item id="UUID for this category">
<title>Title of this category</title>
<summary>Short description of this category</summary>
<list>
<item id="UUID for this item">
<title>Title of this item</title>
<summary>Short description of this item</summary>
<command>The git command to be written in the console</command>
</item>
</list>
</item>
</quickref>
- Top level tag is
quickref
- Contains zero or more
item
- Items directly under
quickref
tag are top level categories
- Contains zero or more
- Item must have an
id
with unique UUID value- Id is unique for entire document, it can be generated using
uuidgen
- Once id assigned to item, it must not changed
- Otherwise it would break saved favorite references
- Id is unique for entire document, it can be generated using
- Item must have
title
andsummary
for describing itself - Item must have either
command
to be written in the consolelist
of zero or more reference items
Current application only accept reference document as
SQLite database with full text search fts4
.
The XML document must be converted to SQLite database
before included in the application. Use simple python
script mkquickref.py
in this repository for conversion.
Below programs are required for conversion
- Python 3.x, for running
mkquickref.py
itself - GNU Make, for executing
Makefile
- Xmllint, for validating XML
Consult distribution package manager to install these programs. If you are using Windows, it is easier to run under Cygwin or MSYS2. Running mkquickref.py directly is possible, but the script expect valid xml input, hence it rely on xmllint validation.
After required programs installed, just run
$ make
If conversion done without error, quickref.sqlite
will be
generated on the same directory.
Go to android git quick reference application project,
copy quickref.sqlite
to the
assets
folder and increase database version number in the version.properties
file.
Build and run the application.
Licensed under same license as the android application.