If you are someone who manages many ODK forms, you might want to explore yxf
: https://github.com/Sjlver/yxf.
yxf
is a tool that converts forms from the XLSForm format to a text-based format. Both versions contain exactly the same information, but text files are a lot easier to store, compare, or bulk-update than spreadsheets.
The text-based format can be converted back into a valid XLSForm file. As a bonus, the result likely looks a lot prettier than the original.
To give an example: yxf
allows you to go from a form to this representation:
survey:
- '#': Converted by yxf, from paani.xlsx. Edit the YAML file instead of the Excel
file.
- type: start
name: start
- type: end
name: end
- type: select_multiple qe3sk00
name: Question
label: Question
required: false
- type: begin_group
name: group_A
label: Question A
relevant: selected(${Question}, 'A')
appearance: field-list
- type: ...
... and back to this:
This is super cool (in my opinion) because it allows you to treat forms like code. You can now store them using a tool like git, easily compare them, perform bulk changes across many versions of a form, etc. For example, here is a comparison between two versions of a form, after a question has been made required:
survey:
- '#': Converted by yxf, from paani.xlsx. Edit the YAML file instead of the Excel
file.
- type: start
name: start
- type: end
name: end
- type: select_multiple qe3sk00
name: Question
label: Question
- required: false
+ required: true
- type: begin_group
name: group_A
label: Question A
relevant: selected(${Question}, 'A')
appearance: field-list
- type: ...
yxf
is in a very early stage of development. We welcome feedback, bug reports, and contributions. If you find yxf
useful, let us know, too