ckanext-intro - A quick interactive introduction to writing CKAN extensions
This is a sample extension, intended as a quick and interactive introduction to writing CKAN extensions. It was used in the CKAN workshop at OKCon 2013.
This does not go into as much details as the proper tutorials for writing extensions. Developers willing to start writing CKAN extensions should use those as they provide all necessary detail:
- Writing extensions tutorial: http://docs.ckan.org/en/latest/extensions/tutorial.html
- Custom theming tutorial: http://docs.ckan.org/en/latest/extensions/theming.html
Requisites
- A running source CKAN 2.1 install (http://docs.ckan.org/en/latest/install-from-source.html)
- A sysadmin user
- Some datasets created
Installation
Install the extension as usual, in your activated virtualenv:
pip install -e git+https://github.com/okfn/ckanext-intro.git#egg=ckanext-intro
If you want to jump straight away to the end result, just add the plugin to your CKAN configuration file:
ckan.plugins = intro_plugin
It is recommended though that you follow the individual steps as described in the next section.
How it works
The repository contains a step-by-step process of building an extension. Each step is contained in a single commit, and flagged with a git tag (step1, step2, …)
You can move between steps using the git checkout command. For example to start on the first step:
git checkout step1
To move to the next step:
git checkout step2
And so on.