Skip to content

edmondatto/ckanext-social

 
 

Repository files navigation

PyPI version GitHub issues GitHub forks GitHub stars GitHub license Twitter

CKAN social

An extension to improve social sharing in CKAN.

With the extension installed and activated:

  • when a user clicks the social share button, the page title is included in the text that pops up.
  • includes open graph tags in the head to facilitate the use of summary cards when sharing to social

Requirements

This extension has been tested with the following versions of CKAN and works well on these installations:

  1. CKAN 2.7.0
  2. CKAN 2.6.3
  3. CKAN 2.5.4

Installation

Installing this extension in your CKAN instance is as easy as installing any other CKAN extension.

Activate your CKAN virtual environment, for example

. /usr/local/lib/ckan/default/bin/activate

Option 1: Install the extension using python setup.py

$ git clone https://github.com/CodeForAfricaLabs/ckanext-social.git
$ cd ckanext-social
$ python setup.py install

Modify your configuration file (generally in /etc/ckan/default/production.ini) and add social in the ckan.plugins property.

ckan.plugins = social <OTHER_PLUGINS>

Option 2: Install the extension using pip install ckanext-social

  1. Install the ckanext-social Python package into your virtual environment:
pip install ckanext-social
  1. Add social to the ckan.plugins setting in your CKAN config file (by default the config file is located at /etc/ckan/default/production.ini).

  2. Restart CKAN. For example if you've deployed CKAN with Apache on Ubuntu:

sudo service apache2 reload

Development Installation

To install ckanext-social for development, activate your CKAN virtualenv and run the following commands

git clone https://github.com/edmondatto/ckanext-social.git
cd ckanext-social
python setup.py develop
pip install -r dev-requirements.txt

Tests

This sofware contains a set of test to detect errors and failures. You can run this tests by running the following command (this command will generate coverage reports):

python setup.py nosetests

Note: The test.ini file contains a link to the CKAN test-core.ini file. You will need to change that link to the real path of the file in your system (generally /usr/local/lib/ckan/default/src/ckan/test-core.ini).

About

Improved social sharing in CKAN.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 72.5%
  • HTML 16.0%
  • Shell 11.5%