Skip to main content

Kibrit -- an open source git version parser for Django

Project description

kibrit
=============

A git version parser for django templates.

Usage:
------

The intent of django_kibrit is to burn the css cache of the client upon a change in the project.

# Somewhere in your templates
<link href="{{ STATIC_URL }}css/screen.css{{ KIBRIT_REVISION }}" media="screen, projection" rel="stylesheet" type="text/css" />

Installation:
------------

pip install django_kibrit

Kibrit makes use of the `memcached` library in django. To enable this place

CACHES = {
'default': {
'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
'LOCATION': '127.0.0.1:11211',
},
}

To use kibrit on your templates append the following 2 lines at the end of your projects `settings.py`.

TEMPLATE_CONTEXT_PROCESSORS += 'barista.kibrit.context_processor.revision',
INSTALLED_APPS += 'django_kibrit',

The package can try to detect .git in your project automatically but it is best if you explicitly set KIBRIT_PATH in your settings to where the .git file is in your project.

KIBRIT_PATH = '/path/to/your/.git/file' # You've found it when 'ls -al | grep .git' prints the .git file

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django_kibrit-0.1.4.tar.gz (4.4 kB view details)

Uploaded Source

File details

Details for the file django_kibrit-0.1.4.tar.gz.

File metadata

  • Download URL: django_kibrit-0.1.4.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for django_kibrit-0.1.4.tar.gz
Algorithm Hash digest
SHA256 47e2b379dd676f3f91d7a46bcaf6b20c47c59659bc67fbf98d4f9cd936eeaed1
MD5 b13e5712c1e73faa30e567591f7d324d
BLAKE2b-256 914961a999f9660751d855cd704b5d25f73dc12aaa0806ffb01c3e4237710a8f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page