Skip to content

Instantly share code, notes, and snippets.

View manuganji's full-sized avatar

Manu Ganji manuganji

View GitHub Profile
import re
from django.utils.text import compress_string
from django.utils.cache import patch_vary_headers
from django import http
from django.conf import settings
manuganji / CsvExport.cs
Last active August 29, 2015 14:13 — forked from jitbit/CsvExport.cs
// Simple C# csv export class
// found here:
// I guess copyright is (c) Chris Hulbert
using System;
using System.Data.SqlTypes;
using System.IO;
using System.Text;
using System.Collections.Generic;
manuganji / postactivate
Last active June 27, 2018 10:07 — forked from unbracketed/gist:228457
virtualenv postactivate and postdeactivate files for django. Place these files at $VIRTUAL_ENV/bin. That is inside the bin folder inside the virtualenv directory
# This hook is run after this virtualenv is activated.
# Place this file at $VIRTUAL_ENV/bin
# I usually drop something like this into my virtualenv's postactivate for some
# quick and handy shortcuts to common Django commands.
# This way dropping in to do some work on any arbitrary project is as easy as:
# 1. workon <project name>
# 2. djr